Better support for noroot
This commit is contained in:
parent
806c1d1510
commit
d783dfcf77
26
tforgione.sh
26
tforgione.sh
@ -109,6 +109,11 @@ ask_for_dotfiles() {
|
||||
}
|
||||
|
||||
ask_for_neovim() {
|
||||
if [ $sudo_available -eq 0 ]; then
|
||||
warn_n "can't install neovim without sudo"
|
||||
return
|
||||
fi
|
||||
|
||||
yes_no_ask "do you wish to install and configure neovim?"
|
||||
if [ $? -ne 0 ]; then
|
||||
return
|
||||
@ -135,6 +140,11 @@ ask_for_rust() {
|
||||
}
|
||||
|
||||
ask_for_python() {
|
||||
if [ $sudo_available -eq 0 ]; then
|
||||
warn_n "can't install python without sudo"
|
||||
return
|
||||
fi
|
||||
|
||||
yes_no_ask "do you wish to install and configure python?"
|
||||
if [ $? -ne 0 ]; then
|
||||
return
|
||||
@ -144,6 +154,11 @@ ask_for_python() {
|
||||
}
|
||||
|
||||
ask_for_nodejs() {
|
||||
if [ $sudo_available -eq 0 ]; then
|
||||
warn_n "can't install node without sudo"
|
||||
return
|
||||
fi
|
||||
|
||||
yes_no_ask "do you wish to install and configure nodejs?"
|
||||
if [ $? -ne 0 ]; then
|
||||
return
|
||||
@ -156,8 +171,12 @@ ask_for_nodejs() {
|
||||
}
|
||||
|
||||
ask_for_hyprland() {
|
||||
if [ $sudo_available -eq 0 ]; then
|
||||
return
|
||||
fi
|
||||
|
||||
if [ $has_pacman -ne 1 ]; then
|
||||
warn_n "tforgione's installer does not support this os for setting up hyprland"
|
||||
warn_n "can't install hyprland on this OS"
|
||||
return
|
||||
fi
|
||||
|
||||
@ -309,6 +328,11 @@ run() {
|
||||
export UPDATE_CHECK=weekly
|
||||
export UPDATE_CHECK_TYPE=sliding
|
||||
$HOME/.config/dotfiles/bin/update postpone
|
||||
|
||||
if [ $sudo_available -eq 0 ]; then
|
||||
mkdir -p $HOME/.config/dotfiles/.data
|
||||
touch $HOME/.config/dotfiles/.data/noroot
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user