Skip to content

Commit d9be498

Browse files
authored
Merge pull request jordansissel#2116 from Tapjoy/ehealy/sh-filter-newer-shell-fuctions
Filter newer style bash functions out of shell script template's .ins…
2 parents 78d08ef + 332d626 commit d9be498

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

templates/sh.erb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,7 @@ function save_environment(){
137137

138138
# just piping env to a file doesn't quote the variables. This does
139139
# filter out multiline junk, _, and functions. _ is a readonly variable.
140-
env | grep -v "^_=" | grep -v "^[^=(]*()=" | egrep "^[^ ]+=" | while read ENVVAR ; do
140+
env | grep -v "^_=" | grep -v "^[^=(]*()=" | grep -v "^BASH_FUNC_.*%%=" |egrep "^[^ ]+=" | while read ENVVAR ; do
141141
local NAME=${ENVVAR%%=*}
142142
# sed is to preserve variable values with dollars (for escaped variables or $() style command replacement),
143143
# and command replacement backticks

0 commit comments

Comments
 (0)