summaryrefslogtreecommitdiff
path: root/etc
diff options
context:
space:
mode:
authorTom Grennan <tgrennan@vyatta.com>2007-09-19 14:19:55 -0700
committerTom Grennan <tgrennan@vyatta.com>2007-09-19 14:19:55 -0700
commita72a48c6e541665c2ae36520f78e7f30c6d72312 (patch)
tree2a0411251a199f442191adaf3a46090fbd050c92 /etc
parent607ab1113fd68be09b0bf40a8ae04a5a077aecfb (diff)
downloadvyatta-op-a72a48c6e541665c2ae36520f78e7f30c6d72312.tar.gz
vyatta-op-a72a48c6e541665c2ae36520f78e7f30c6d72312.zip
fix linda/lintian detected errors
Diffstat (limited to 'etc')
-rw-r--r--etc/bash_completion.d/vyatta-op15
-rw-r--r--etc/default/vyatta.in15
2 files changed, 13 insertions, 17 deletions
diff --git a/etc/bash_completion.d/vyatta-op b/etc/bash_completion.d/vyatta-op
index 8e4d79f..23bd294 100644
--- a/etc/bash_completion.d/vyatta-op
+++ b/etc/bash_completion.d/vyatta-op
@@ -1,5 +1,4 @@
-#!/bin/bash
-#
+
# **** License ****
# Version: VPL 1.0
#
@@ -31,8 +30,6 @@ for e ; do
eval $e
fi
done
-eval $_vyatta_extglob
-unset _vyatta_extglob
test -f /etc/default/vyatta && source /etc/default/vyatta
@@ -69,16 +66,14 @@ _vyatta_op_set_allowed_subdirs ()
{
local dir=$1
- _vyatta_op_allowed=(
- $( find ${vyatta_op_templates}$1/* -maxdepth 0 -type d -printf %f\\n ))
+ _vyatta_op_allowed=($( find ${vyatta_op_templates}$1/* -maxdepth 0 -type d -printf %f\\n ))
}
_vyatta_op_set_allowed ()
{
local nullglob=$( shopt -p nullglob )
shopt -s nullglob
- _vyatta_op_allowed=($(
- eval "$( _vyatta_op_get_node_def_field $_vyatta_op_node_def allowed )" ))
+ _vyatta_op_allowed=($( eval "$( _vyatta_op_get_node_def_field $_vyatta_op_node_def allowed )" ))
eval $nullglob
}
@@ -178,7 +173,7 @@ done
if [[ -d $vyatta_op_templates ]]
then
- for xd in ${vyatta_op_templates}/!(README|*~|*.bak|*.swp|\#*\#) ; do
+ for xd in $vyatta_op_templates/* ; do
if [ -d $xd ] ; then
cmd=${xd##*/}
complete -F _vyatta_op_expand -o nospace $cmd
@@ -190,6 +185,8 @@ fi
bind -x '"\e?": _vyatta_op_help'
shopt -s histverify
+eval $_vyatta_extglob
+unset _vyatta_extglob
### Local Variables:
### mode: shell-script
diff --git a/etc/default/vyatta.in b/etc/default/vyatta.in
index be92ada..d3191fd 100644
--- a/etc/default/vyatta.in
+++ b/etc/default/vyatta.in
@@ -1,6 +1,5 @@
-#!/bin/bash
-# declare configred Vyatta shell environment variables
+# declare configured Vyatta shell environment variables
# first set vars per args of the "source /etc/default/vyatta VAR=FOO"
_vyatta_extglob=$(shopt -p extglob)
@@ -65,20 +64,20 @@ unset _vyatta_extglob
else
declare -x -r vyatta_libdir=$vyatta_exec_prefix/lib
fi
- fi
+ fi
if test -z "$vyatta_libexecdir" ; then
if test -n "@libexecdir@" ; then
declare -x -r vyatta_libexecdir=@libexecdir@
else
declare -x -r vyatta_libexecdir=$vyatta_exec_prefix/libexec
- fi
+ fi
fi
if test -z "$vyatta_datadir" ; then
if test -n "@datadir@" ; then
declare -x -r vyatta_datadir=@datadir@
else
declare -x -r vyatta_datadir=$vyatta_datarootdir
- fi
+ fi
fi
if test -z "$vyatta_htmldir" ; then
if test -n "@htmldir@" ; then
@@ -86,7 +85,7 @@ unset _vyatta_extglob
else
declare -x -r vyatta_htmldir=$vyatta_datarootdir/html
fi
- fi
+ fi
if test -z "$vyatta_infodir" ; then
if test -n "@infodir@" ; then
declare -x -r vyatta_infodir=@infodir@
@@ -98,7 +97,7 @@ unset _vyatta_extglob
if test -n "@mandir@" ; then
declare -x -r vyatta_htmldir=@mandir@
else
- declare -x -r vyatta_htmldir=$vyatta_datarootdir/man
+ declare -x -r vyatta_htmldir=$vyatta_datarootdir/man
fi
fi
if test -z "$vyatta_localedir" ; then
@@ -113,7 +112,7 @@ unset _vyatta_extglob
declare -x -r vyatta_localstatedir=@localstatedir@
else
declare -x -r vyatta_localstatedir=$vyatta_prefix/var
- fi
+ fi
fi
if test -z "$vyatta_sharedstatedir" ; then
if test -n "@sharedstatedir@" ; then