Update firstboot-setup.sh
This commit is contained in:
@@ -4,14 +4,14 @@ set -euo pipefail
|
|||||||
DIALOG=dialog
|
DIALOG=dialog
|
||||||
HEIGHT=20
|
HEIGHT=20
|
||||||
WIDTH=74
|
WIDTH=74
|
||||||
LOG="/var/log/firstboot-setup.log"
|
LOG="$HOME/.local/state/firstboot-setup.log"
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
if [[ -z "${TERM:-}" ]]; then
|
if [[ -z "${TERM:-}" ]]; then
|
||||||
exec cosmic-terminal -- /usr/libexec/firstboot-setup.sh
|
exec cosmic-terminal -- "$HOME/.config/firstboot/firstboot-user.sh"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
exec > >(tee -a "$LOG") 2>&1
|
exec > >(tee -a "$LOG") 2>&1
|
||||||
|
|
||||||
abort() {
|
abort() {
|
||||||
@@ -28,12 +28,14 @@ wirklich abbrechen?" \
|
|||||||
$HEIGHT $WIDTH
|
$HEIGHT $WIDTH
|
||||||
|
|
||||||
if [[ $? -eq 0 ]]; then
|
if [[ $? -eq 0 ]]; then
|
||||||
systemctl start firstboot-cleanup.service
|
rm -f "$HOME/.config/firstboot/run"
|
||||||
systemctl --user disable firstboot-setup.service
|
systemctl --user disable firstboot-setup.service
|
||||||
clear
|
clear
|
||||||
exit 0
|
exit 0
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
fi
|
||||||
|
|
||||||
# User hat sich gegen Abbruch entschieden → zurück
|
# User hat sich gegen Abbruch entschieden → zurück
|
||||||
return 0
|
return 0
|
||||||
}
|
}
|
||||||
@@ -293,8 +295,9 @@ $HEIGHT $WIDTH 0
|
|||||||
# ----------------------------
|
# ----------------------------
|
||||||
# Mark wizard as done
|
# Mark wizard as done
|
||||||
# ----------------------------
|
# ----------------------------
|
||||||
systemctl start firstboot-cleanup.service
|
rm -f "$HOME/.config/firstboot/run"
|
||||||
systemctl --user disable firstboot-setup.service
|
systemctl --user disable firstboot-user.service
|
||||||
|
|
||||||
|
|
||||||
$DIALOG --title "Fertig" --msgbox \
|
$DIALOG --title "Fertig" --msgbox \
|
||||||
"Die Einrichtung ist abgeschlossen.
|
"Die Einrichtung ist abgeschlossen.
|
||||||
|
|||||||
Reference in New Issue
Block a user