Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Allow environment variables to contain colons (#3283)
* Allow environment variables to contain colons Currently, any environment variables that have colon in them are discarded, including any text following them. This pr includes them. **Before:** ``` URL:http://localhost:4200 = ['URL', 'http'] ``` **After:** ``` URL:http://localhost:4200 = ['URL', 'http://localhost:4200'] ``` **Example:** https://jsbin.com/mexeyifuqi/1/edit?js,console * Add test. * Update conditional that sets env variables.
- Loading branch information
1 parent
a5502ad
commit 878ac03
Showing
4 changed files
with
9 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
module.exports = { | ||
description: 'passes environment variables to config file', | ||
command: 'rollup --config --environment PRODUCTION,FOO:bar', | ||
command: 'rollup --config --environment PRODUCTION,FOO:bar,HOST:http://localhost:4000', | ||
execute: true | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,3 @@ | ||
assert.equal( '__ENVIRONMENT__', 'production' ); | ||
assert.equal( '__FOO__', 'bar' ); | ||
assert.equal( '__HOST__', 'http://localhost:4000' ); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters