mirror of
https://gitlab.manjaro.org/applications/manjaro-architect
synced 2024-11-08 01:10:26 +00:00
commit
3e38f5523a
11
lib/util.sh
11
lib/util.sh
@ -148,20 +148,21 @@ id_system() {
|
|||||||
check_for_error() {
|
check_for_error() {
|
||||||
local _msg="$1"
|
local _msg="$1"
|
||||||
local _err="${2:-0}"
|
local _err="${2:-0}"
|
||||||
|
local _canceldlg=1
|
||||||
((${_err}!=0)) && _msg="[${_msg}][${_err}]"
|
((${_err}!=0)) && _msg="[${_msg}][${_err}]"
|
||||||
[[ -f "${ERR}" ]] && {
|
[[ -f "${ERR}" ]] && {
|
||||||
_msg="${_msg} $(head -n1 ${ERR})"
|
_msg="${_msg} $(head -n1 ${ERR})"
|
||||||
|
_canceldlg=0 # not btn cancel
|
||||||
rm "${ERR}"
|
rm "${ERR}"
|
||||||
}
|
}
|
||||||
if ((${_err}!=0)); then
|
if ((${_err}!=0)) && ((${_canceldlg}==0)); then
|
||||||
# and function varsdump ? _msg="$_msg \n $(declare -p | grep -v " _")"
|
# and function varsdump ? _msg="$_msg \n $(declare -p | grep -v " _")"
|
||||||
echo -e "$(date +%D\ %T) ERROR ${_msg}" >> "${LOGFILE}"
|
echo -e "$(date +%D\ %T) ERROR ${_msg}" >> "${LOGFILE}"
|
||||||
DIALOG " $_ErrTitle " --msgbox "\n${_msg}\n" 0 0
|
DIALOG " $_ErrTitle " --msgbox "\n${_msg}\n" 0 0
|
||||||
main_menu_online
|
main_menu_online
|
||||||
else
|
else
|
||||||
echo -e "$(date +%D\ %T) ${_msg}" >> "${LOGFILE}"
|
echo -e "$(date +%D\ %T) ${_msg}" >> "${LOGFILE}"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
# Add locale on-the-fly and sets source translation file for installer
|
# Add locale on-the-fly and sets source translation file for installer
|
||||||
|
Loading…
Reference in New Issue
Block a user