Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Multiple env files possible? #140

Open
joeldebont opened this issue Oct 27, 2023 · 1 comment
Open

Multiple env files possible? #140

joeldebont opened this issue Oct 27, 2023 · 1 comment
Labels
question Further information is requested

Comments

@joeldebont
Copy link

joeldebont commented Oct 27, 2023

Hello,

I'm working on a white-label react native app where I have an env file per app version so each version has its own variable values. Now I also have variables that are needed in all app versions so I would like to have a general env file to store them in so I don't have to put those variables in all the other env files.

Is it possible to have multiple env files that are combined in a single config when running yarn rnuc?

I could'nt find it in the docs, but maybe I have missed it.

Cheers!

@joeldebont joeldebont added the question Further information is requested label Oct 27, 2023
@maxkomarychev
Copy link
Owner

Hi @joeldebont, thanks for using the library!

Inheritance or merging from multiple env files is not supported directly. However you could achieve this behavior using on_env hook and override / enrich original env data with shared values. Please refer to cookbook for more details: https://github.com/maxkomarychev/react-native-ultimate-config/blob/master/docs/cookbook.md

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants