mirror of
https://gitlab.archlinux.org/tpowa/archboot.git
synced 2024-09-20 03:50:37 +02:00
add message before setting root password.
This commit is contained in:
parent
1ac51c841c
commit
18472515e6
1 changed files with 8 additions and 2 deletions
|
@ -2,9 +2,15 @@
|
|||
# created by Tobias Powalowski <tpowa@archlinux.org>
|
||||
check_root_password() {
|
||||
# check if empty password is set
|
||||
chroot "${DESTDIR}" passwd -S root | cut -d ' ' -f2 | grep -q NP && set_password
|
||||
if chroot "${DESTDIR}" passwd -S root | cut -d ' ' -f2 | grep -q NP; then
|
||||
DIALOG --msgbox "Setup detected empty password set for root user, please set password now." 18 70
|
||||
set_password
|
||||
fi
|
||||
# check if account is locked
|
||||
chroot "${DESTDIR}" passwd -S root | cut -d ' ' -f2 | grep -q L && set_password
|
||||
if chroot "${DESTDIR}" passwd -S root | cut -d ' ' -f2 | grep -q L; then
|
||||
DIALOG --msgbox "Setup detected locked account for root user, please set password to unlock account now." 18 70
|
||||
set_password
|
||||
fi
|
||||
}
|
||||
|
||||
set_mkinitcpio() {
|
||||
|
|
Loading…
Reference in a new issue