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
# Fish shell | |
egrep "^export " ~/.bash_profile | while read e | |
set var (echo $e | sed -E "s/^export ([A-Za-z_]+)=(.*)\$/\1/") | |
set value (echo $e | sed -E "s/^export ([A-Za-z_]+)=(.*)\$/\2/") | |
# remove surrounding quotes if existing | |
set value (echo $value | sed -E "s/^\"(.*)\"\$/\1/") | |
if test $var = "PATH" |