Package configurations taking priority over environment variables
Opened this issue · 0 comments
Enet4 commented
I have a use case where I would like environment variable definitions to override properties to envify, the default values of which would be contained in the package.json file. Something like this:
"scripts" {
"build-yes": "MY_VAR=YES browserify .",
"build": "browserify ."
},
"browserify": {
"transform": [
"babelify",
"browserify-shim",
[
"envify",
{
"MY_VAR": "NO"
}
]
]
}
Unfortunately, the re-definition derived from the script "build-yes" does not take place. Removing the definition of "MY_VAR":"NO"
in the package is the only way for "MY_VAR=YES"
to reach the transform. Is this the desired behaviour? Could these priorities be reconsidered?