mirror of
https://github.com/natelandau/shell-scripting-templates.git
synced 2025-11-10 22:13:48 -05:00
minor update
This commit is contained in:
@@ -49,8 +49,7 @@ function _alert() { #my function
|
|||||||
fi
|
fi
|
||||||
if [ "${1}" = "input" ]; then
|
if [ "${1}" = "input" ]; then
|
||||||
local color="${bold}"
|
local color="${bold}"
|
||||||
# Don't print user questions to $logFile
|
savedvar="${printLog}" # Don't print user questions to $logFile
|
||||||
savedvar="${printLog}"
|
|
||||||
printLog="0"
|
printLog="0"
|
||||||
fi
|
fi
|
||||||
if [ "${1}" = "info" ] || [ "${1}" = "notice" ]; then
|
if [ "${1}" = "info" ] || [ "${1}" = "notice" ]; then
|
||||||
@@ -77,8 +76,8 @@ function warning () { local _message="${@}"; echo "$(_alert warning)"; }
|
|||||||
function notice () { local _message="${@}"; echo "$(_alert notice)"; }
|
function notice () { local _message="${@}"; echo "$(_alert notice)"; }
|
||||||
function info () { local _message="${@}"; echo "$(_alert info)"; }
|
function info () { local _message="${@}"; echo "$(_alert info)"; }
|
||||||
function debug () { local _message="${@}"; echo "$(_alert debug)"; }
|
function debug () { local _message="${@}"; echo "$(_alert debug)"; }
|
||||||
function success () { local _message="${@}"; echo "$(_alert success)"; printLog="${savedvar}"; }
|
function success () { local _message="${@}"; echo "$(_alert success)"; }
|
||||||
function input() { local _message="${@}"; echo "$(_alert input)"; }
|
function input() { local _message="${@}"; echo "$(_alert input)"; printLog="${savedvar}"; }
|
||||||
function header() { local _message="========== ${@} ========== "; echo "$(_alert header)"; }
|
function header() { local _message="========== ${@} ========== "; echo "$(_alert header)"; }
|
||||||
|
|
||||||
# Log messages when verbose is set to "1"
|
# Log messages when verbose is set to "1"
|
||||||
|
|||||||
Reference in New Issue
Block a user