Skip to content

Commit 73d04a5

Browse files
committed
Set IFS as local variable to prevent changing global env var
1 parent 654a702 commit 73d04a5

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

lib/App/Spec/Completion/Bash.pm

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,8 +53,9 @@ $completion_outer
5353
5454
_${appname}_compreply() \{
5555
local prefix=""
56+
local IFS=\$'\\n'
5657
cur="\$(printf '%q' "\$cur")"
57-
IFS=\$'\\n' COMPREPLY=(\$(compgen -P "\$prefix" -W "\$*" -- "\$cur"))
58+
IFS=\$IFS COMPREPLY=(\$(compgen -P "\$prefix" -W "\$*" -- "\$cur"))
5859
__ltrim_colon_completions "\$prefix\$cur"
5960
6061
# http://stackoverflow.com/questions/7267185/bash-autocompletion-add-description-for-possible-completions

0 commit comments

Comments
 (0)