mirror of
https://github.com/vinceliuice/grub2-themes.git
synced 2024-12-24 19:15:21 +01:00
update
This commit is contained in:
parent
19435ba254
commit
8de4deae26
19
install.sh
19
install.sh
@ -99,8 +99,8 @@ install() {
|
|||||||
local icon="white"
|
local icon="white"
|
||||||
else
|
else
|
||||||
local icon="color"
|
local icon="color"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Checking for root access and proceed if it is present
|
# Checking for root access and proceed if it is present
|
||||||
if [ "$UID" -eq "$ROOT_UID" ]; then
|
if [ "$UID" -eq "$ROOT_UID" ]; then
|
||||||
clear
|
clear
|
||||||
@ -158,13 +158,13 @@ install() {
|
|||||||
# persisted execution of the script as root
|
# persisted execution of the script as root
|
||||||
if [[ -n ${tui_root_login} ]] ; then
|
if [[ -n ${tui_root_login} ]] ; then
|
||||||
if [[ -n "${theme}" && -n "${screen}" ]]; then
|
if [[ -n "${theme}" && -n "${screen}" ]]; then
|
||||||
sudo -S <<< ${tui_root_login} $0 ${ORIGINAL_ARGUMENTS}
|
sudo -S <<< ${tui_root_login} $0 --${theme} --${icon} --${screen}
|
||||||
fi
|
fi
|
||||||
else
|
else
|
||||||
read -p "[ Trusted ] Specify the root password : " -t${MAX_DELAY} -s
|
read -p "[ Trusted ] Specify the root password : " -t${MAX_DELAY} -s
|
||||||
[[ -n "$REPLY" ]] && {
|
[[ -n "$REPLY" ]] && {
|
||||||
if [[ -n "${theme}" && -n "${screen}" ]]; then
|
if [[ -n "${theme}" && -n "${screen}" ]]; then
|
||||||
sudo -S <<< $REPLY $0 ${ORIGINAL_ARGUMENTS}
|
sudo -S <<< $REPLY $0 --${theme} --${icon} --${screen}
|
||||||
fi
|
fi
|
||||||
} || {
|
} || {
|
||||||
operation_canceled
|
operation_canceled
|
||||||
@ -179,13 +179,13 @@ run_dialog() {
|
|||||||
tui_root_login=$(dialog --backtitle ${Project_Name} \
|
tui_root_login=$(dialog --backtitle ${Project_Name} \
|
||||||
--title "ROOT LOGIN" \
|
--title "ROOT LOGIN" \
|
||||||
--insecure \
|
--insecure \
|
||||||
--passwordbox "require root permission" 8 50 \
|
--passwordbox "require root permission" 8 50 \
|
||||||
--output-fd 1 )
|
--output-fd 1 )
|
||||||
[[ -z ${tui_root_login} ]] && exit ${UID}
|
[[ -z ${tui_root_login} ]] && exit ${UID}
|
||||||
sudo -S <<< $tui_root_login $0
|
sudo -S <<< $tui_root_login $0
|
||||||
test $? -eq 0 || {
|
test $? -eq 0 || {
|
||||||
prompt -e "\n [ Error! ] -> wrong passwords"
|
prompt -e "\n [ Error! ] -> wrong passwords"
|
||||||
exit 1
|
exit 1
|
||||||
}
|
}
|
||||||
tui=$(dialog --backtitle ${Project_Name} \
|
tui=$(dialog --backtitle ${Project_Name} \
|
||||||
--radiolist "Choose your Grub theme : " 15 40 5 \
|
--radiolist "Choose your Grub theme : " 15 40 5 \
|
||||||
@ -337,7 +337,6 @@ if [[ $# -lt 1 ]] && [[ $UID -ne $ROOT_UID ]] && [[ ! -x /usr/bin/dialog ]] ; t
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
while [[ $# -ge 1 ]]; do
|
while [[ $# -ge 1 ]]; do
|
||||||
ORIGINAL_ARGUMENTS="$ORIGINAL_ARGUMENTS $1"
|
|
||||||
case "${1}" in
|
case "${1}" in
|
||||||
-b|--boot)
|
-b|--boot)
|
||||||
THEME_DIR="/boot/grub/themes"
|
THEME_DIR="/boot/grub/themes"
|
||||||
|
Loading…
Reference in New Issue
Block a user