diff options
Diffstat (limited to 'etc/bash_completion.d/10vyatta-op')
-rw-r--r-- | etc/bash_completion.d/10vyatta-op | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/etc/bash_completion.d/10vyatta-op b/etc/bash_completion.d/10vyatta-op index 7aa29a3..0651618 100644 --- a/etc/bash_completion.d/10vyatta-op +++ b/etc/bash_completion.d/10vyatta-op @@ -43,13 +43,6 @@ _vyatta_op_debug () _vyatta_op_init () { - local restore_shopts=$( shopt -p nullglob | tr \\n \; ) - shopt -s nullglob - for f in ${vyatta_datadir}/vyatta-op/functions/allowed/* ; do - source $f - done - eval $restore_shopts - complete -F _vyatta_op_expand '' for xd in $vyatta_op_templates/* ; do @@ -275,6 +268,14 @@ if [ "$_OFR_CONFIGURE" == "ok" ]; then return 0 fi +nullglob_save=$( shopt -p nullglob ) +shopt -s nullglob +for f in ${vyatta_datadir}/vyatta-op/functions/allowed/* ; do + source $f +done +eval $nullglob_save +unset nullglob_save + _vyatta_op_init $@ ### Local Variables: |