Created
October 11, 2013 14:22
-
-
Save zipizap/6935448 to your computer and use it in GitHub Desktop.
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
$env | grep VAR | |
# nothing | |
$ VAR1="my_v1" VAR2="my_v2" bash -c 'env | grep VAR' | |
VAR1=my_v1 | |
VAR2=my_v2 | |
# the command after VAR1 and VAR2 has those vars defined in its environment | |
# but the vars only exist in the environment of that command, and not in the | |
# "outside" environment, as can be seen: | |
$ env | grep VAR | |
# nothing |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment