mirror of https://github.com/Llewellynvdm/Tomb.git
fix shellcheck linter
This commit is contained in:
parent
8ceeca8769
commit
6955719f04
2
Makefile
2
Makefile
|
@ -26,4 +26,4 @@ test:
|
||||||
make -C extras/test
|
make -C extras/test
|
||||||
|
|
||||||
lint:
|
lint:
|
||||||
shellcheck -s zsh -e SC1073,SC1027,SC1072,SC1083,SC1009 tomb
|
shellcheck -s bash -e SC1058,SC1073,SC1072,SC1009 tomb
|
||||||
|
|
24
tomb
24
tomb
|
@ -131,7 +131,7 @@ _sudo() {
|
||||||
_failure "Super user execution not supported: ::1 sudo::" "`option_value --sudo`"
|
_failure "Super user execution not supported: ::1 sudo::" "`option_value --sudo`"
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
else
|
else
|
||||||
local msg="[sudo] Enter password for user ::1 user:: to gain superuser privileges"
|
local msg="[sudo] Enter password for user ::1 user:: to gain superuser privileges"
|
||||||
command -v gettext 1>/dev/null 2>/dev/null && msg="$(gettext -s "$msg")"
|
command -v gettext 1>/dev/null 2>/dev/null && msg="$(gettext -s "$msg")"
|
||||||
|
@ -183,15 +183,15 @@ _endgame() {
|
||||||
}
|
}
|
||||||
|
|
||||||
# Trap functions for the _endgame event
|
# Trap functions for the _endgame event
|
||||||
TRAPINT() { _endgame INT }
|
TRAPINT() { _endgame INT; }
|
||||||
TRAPEXIT() { _endgame EXIT }
|
TRAPEXIT() { _endgame EXIT; }
|
||||||
TRAPHUP() { _endgame HUP }
|
TRAPHUP() { _endgame HUP; }
|
||||||
TRAPQUIT() { _endgame QUIT }
|
TRAPQUIT() { _endgame QUIT; }
|
||||||
TRAPABRT() { _endgame ABORT }
|
TRAPABRT() { _endgame ABORT; }
|
||||||
TRAPKILL() { _endgame KILL }
|
TRAPKILL() { _endgame KILL; }
|
||||||
TRAPPIPE() { _endgame PIPE }
|
TRAPPIPE() { _endgame PIPE; }
|
||||||
TRAPTERM() { _endgame TERM }
|
TRAPTERM() { _endgame TERM; }
|
||||||
TRAPSTOP() { _endgame STOP }
|
TRAPSTOP() { _endgame STOP; }
|
||||||
|
|
||||||
_is_found() {
|
_is_found() {
|
||||||
# returns 0 if binary is found in path
|
# returns 0 if binary is found in path
|
||||||
|
@ -1445,7 +1445,7 @@ gen_key() {
|
||||||
# Set gpg inputs and options
|
# Set gpg inputs and options
|
||||||
gpgpass="$TOMBSECRET"
|
gpgpass="$TOMBSECRET"
|
||||||
opt=''
|
opt=''
|
||||||
else
|
else
|
||||||
if [ "$2" = "" ]; then
|
if [ "$2" = "" ]; then
|
||||||
while true; do
|
while true; do
|
||||||
# 3 tries to write two times a matching password
|
# 3 tries to write two times a matching password
|
||||||
|
@ -2065,7 +2065,7 @@ lock_tomb_with_key() {
|
||||||
return 1
|
return 1
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
is_valid_tomb $tombpath
|
is_valid_tomb $tombpath
|
||||||
|
|
||||||
_message "Commanded to lock tomb ::1 tomb file::" $TOMBFILE
|
_message "Commanded to lock tomb ::1 tomb file::" $TOMBFILE
|
||||||
|
|
Loading…
Reference in New Issue