More travis-ci related cleanup
* Remove SC2006 from shellcheck: bashism * Put variable declarations on separate lines (SC1007) * Remove "local" from Windows sh script (SC2039) * Remove "x" variable define from read in Windows sh script (SC2034) Signed-off-by: Eric F Crist <ecrist@secure-computing.net>
This commit is contained in:
parent
fe7cbae65d
commit
b5803ee9e3
@ -10,4 +10,4 @@ addons:
|
|||||||
- shellcheck
|
- shellcheck
|
||||||
|
|
||||||
script:
|
script:
|
||||||
- bash -c 'shopt -s globstar; shellcheck **/*.sh easyrsa3/easyrsa'
|
- bash -c 'export SHELLCHECK_OPTS="-e SC2006"; shopt -s globstar; shellcheck **/*.sh easyrsa3/easyrsa'
|
||||||
|
|||||||
@ -1,4 +1,5 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
# shellcheck disable=
|
||||||
|
|
||||||
# Easy-RSA 3 distribution packager:
|
# Easy-RSA 3 distribution packager:
|
||||||
# creates ready-to-use tarball files for Unixes and a zip file for windows
|
# creates ready-to-use tarball files for Unixes and a zip file for windows
|
||||||
|
|||||||
@ -24,7 +24,7 @@ for f in $extern_list; do
|
|||||||
echo " files."
|
echo " files."
|
||||||
echo ""
|
echo ""
|
||||||
echo " Press enter to exit."
|
echo " Press enter to exit."
|
||||||
read x
|
read
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
@ -32,9 +32,9 @@ done
|
|||||||
# set_var is defined as any vars file needs it.
|
# set_var is defined as any vars file needs it.
|
||||||
# This is the same as in easyrsa, but we _don't_ export
|
# This is the same as in easyrsa, but we _don't_ export
|
||||||
set_var() {
|
set_var() {
|
||||||
local var=$1
|
var="$1"
|
||||||
shift
|
shift
|
||||||
local value="$*"
|
value="$*"
|
||||||
eval "$var=\"\${$var-$value}\""
|
eval "$var=\"\${$var-$value}\""
|
||||||
} #=> set_var()
|
} #=> set_var()
|
||||||
|
|
||||||
@ -62,4 +62,4 @@ echo ""
|
|||||||
echo "Invoke './easyrsa' to call the program. Without commands, help is displayed."
|
echo "Invoke './easyrsa' to call the program. Without commands, help is displayed."
|
||||||
|
|
||||||
# Drop to a shell and await input
|
# Drop to a shell and await input
|
||||||
bin/sh
|
bin/sh
|
||||||
|
|||||||
@ -59,7 +59,8 @@ DIRECTORY STATUS (commands would take effect on these locations)
|
|||||||
# Detailed command help
|
# Detailed command help
|
||||||
# When called with no args, calls usage(), otherwise shows help for a command
|
# When called with no args, calls usage(), otherwise shows help for a command
|
||||||
cmd_help() {
|
cmd_help() {
|
||||||
text= opts=
|
text=""
|
||||||
|
opts=""
|
||||||
case "$1" in
|
case "$1" in
|
||||||
init-pki|clean-all) text="
|
init-pki|clean-all) text="
|
||||||
init-pki [ cmd-opts ]
|
init-pki [ cmd-opts ]
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user