From a5af81b784ee6866848c2f027cc9f0acaaf15015 Mon Sep 17 00:00:00 2001 From: Solomon Laing Date: Sat, 28 Aug 2021 22:10:33 +0930 Subject: [PATCH] minor changes --- install-config | 2 ++ install-defaults | 3 +++ install-dependencies | 8 ++++++-- install-dmenu-inkletblot | 2 ++ install-misc | 3 +++ install-scripts | 2 ++ install-yay | 4 +++- setup | 8 +++----- 8 files changed, 24 insertions(+), 8 deletions(-) diff --git a/install-config b/install-config index b52f58f..3dc888b 100755 --- a/install-config +++ b/install-config @@ -8,6 +8,8 @@ # Installs my customisation of dmenu #----------------------------------- +clear + echo "This script is going to install dmenu-inkletblot, my fork of dmenu with my custom styling. As such it will ask for root privilages." read -r -p "Are You Sure? [y/N] " input diff --git a/install-defaults b/install-defaults index 0ef6c2a..d3057b1 100755 --- a/install-defaults +++ b/install-defaults @@ -1,5 +1,7 @@ #!/bin/sh +clear + default_programs="./default-programs" dependencies=$(sed -n '/DEFAULTS_START/,/DEFAULTS_END/p' $default_programs | sed -e 's/DEFAULTS_START//' -e 's/DEFAULTS_END//') @@ -30,6 +32,7 @@ failures=() # run though each dependency and install it if it's not already installed for dependency in $dependencies do + clear if ! yay -Qi $dependency &> /dev/null; then echo "Installing $dependency and it's dependencies..." yay -S --noconfirm $dependency &> /dev/null diff --git a/install-dependencies b/install-dependencies index f7d72e5..c2af88b 100755 --- a/install-dependencies +++ b/install-dependencies @@ -1,5 +1,7 @@ #!/bin/sh +clear + default_programs="./default-programs" dependencies=$(sed -n '/DEPENDENCIES_START/,/DEPENDENCIES_END/p' $default_programs | sed -e 's/DEPENDENCIES_START//' -e 's/DEPENDENCIES_END//') laptop_dependencies=$(sed -n '/DEPENDENCIES_LAPTOP_START/,/DEPENDENCIES_LAPTOP_END/p' $default_programs | sed -e 's/DEPENDENCIES_LAPTOP_START//' -e 's/DEPENDENCIES_LAPTOP_END//') @@ -50,9 +52,10 @@ failures=() # run though each dependency and install it if it's not already installed for dependency in $dependencies do + clear if ! yay -Qi $dependency &> /dev/null; then echo "Installing $dependency and it's dependencies..." - yay -S --noconfirm $dependency &> /dev/null + yay -S --noconfirm $dependency fi if ! yay -Qi $dependency &> /dev/null; then @@ -64,9 +67,10 @@ if [ $laptop -eq 1 ]; then # run though each laptop dependency and install it if it's not already installed for dependency in $laptop_dependencies do + clear if ! yay -Qi $dependency &> /dev/null; then echo "Installing $dependency and it's dependencies..." - yay -S --noconfirm $dependency &> /dev/null + yay -S --noconfirm $dependency fi if ! yay -Qi $dependency &> /dev/null; then diff --git a/install-dmenu-inkletblot b/install-dmenu-inkletblot index 1c061b1..7661400 100755 --- a/install-dmenu-inkletblot +++ b/install-dmenu-inkletblot @@ -8,6 +8,8 @@ # Installs my customisation of dmenu #----------------------------------- +clear + if command -v dmenu &> /dev/null; then echo "dmenu is already installed on the system." exit 0 diff --git a/install-misc b/install-misc index c0a1c68..61b38e9 100755 --- a/install-misc +++ b/install-misc @@ -1,5 +1,7 @@ #!/bin/sh +clear + default_programs="./default-programs" dependencies=$(sed -n '/MISC_START/,/MISC_END/p' $default_programs | sed -e 's/MISC_START//' -e 's/MISC_END//') @@ -30,6 +32,7 @@ failures=() # run though each dependency and install it if it's not already installed for dependency in $dependencies do + clear if ! yay -Qi $dependency &> /dev/null; then echo "Installing $dependency and it's dependencies..." yay -S --noconfirm $dependency &> /dev/null diff --git a/install-scripts b/install-scripts index b5626d1..c5e64a5 100755 --- a/install-scripts +++ b/install-scripts @@ -1,5 +1,7 @@ #!/bin/sh +clear + # check user is happy to run this script echo "This script is going to install all of the programs listed in /home//default-programs and their dependencies. As such it will ask for root privilages." read -r -p "Are you sure you want to continue? [y/N] " input diff --git a/install-yay b/install-yay index 6d03548..1e4648c 100755 --- a/install-yay +++ b/install-yay @@ -9,6 +9,8 @@ # system. #----------------------------------- +clear + if command -v yay &> /dev/null; then echo "yay is already installed on the system." exit 0 @@ -32,7 +34,7 @@ case $input in esac if ! command -v fakeroot &> /dev/null; then - sudo -S pacman -Sy --noconfirm base-devel + sudo pacman -S --noconfirm base-devel fi cd /opt diff --git a/setup b/setup index f6ef95d..a736ecd 100755 --- a/setup +++ b/setup @@ -125,11 +125,13 @@ echo "" echo "Note: it is expected that the initial run of this script lets each stage complete sucessfully." } +update_system +git submodule init +git submodule update case $1 in "") install_yay - update_system install_dependencies install_defaults install_misc @@ -142,7 +144,6 @@ case $1 in install_yay else install_yay - update_system install_dependencies install_defaults install_misc @@ -152,7 +153,6 @@ case $1 in fi ;; deps) - update_system if [ "$2" = "only" ]; then install_dependencies else @@ -165,7 +165,6 @@ case $1 in fi ;; defaults) - update_system if [ "$2" = "only" ]; then install_defaults else @@ -177,7 +176,6 @@ case $1 in fi ;; misc) - update_system if [ "$2" = "only" ]; then install_misc else