Last active
September 6, 2019 04:05
-
-
Save yaasita/184822733558cdcad73632adf7a8cf02 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
#!/bin/bash | |
export MAIN1="exportした変数" | |
MAIN2="普通の変数" | |
exec ./sub.sh | |
echo "この行は実行されない" |
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
#!/bin/bash | |
export MAIN1="exportした変数" | |
MAIN2="普通の変数" | |
source ./sub.sh | |
echo "この行は実行される" | |
echo $SUB1 | |
echo $SUB2 |
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
#!/bin/bash | |
echo $MAIN1 | |
echo $MAIN2 | |
export SUB1="subでexportした変数" | |
SUB2="subの普通な変数" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment