ok I figured it out why
This commit is contained in:
@@ -6,7 +6,7 @@
|
||||
|
||||
## WARNING: DO NOT EDIT BEYOND THIS LINE IF YOU DON'T KNOW WHAT YOU ARE DOING! ##
|
||||
# Set the name of the log file to include the current date and time
|
||||
LOG="Install-Logs/install-$(date +%d-%H%M%S)_yay.log"
|
||||
LOG="install-$(date +%d-%H%M%S)_yay.log"
|
||||
|
||||
# Set some colors for output messages
|
||||
OK="$(tput setaf 2)[OK]$(tput sgr0)"
|
||||
@@ -23,6 +23,11 @@ if [ ! -d Install-Logs ]; then
|
||||
mkdir Install-Logs
|
||||
fi
|
||||
|
||||
# Check Existing yay-bin
|
||||
if [ ! -d yay-bin ]; then
|
||||
rm -rf yay-bin 2>&1 | tee -a "$LOG"
|
||||
fi
|
||||
|
||||
# Check for AUR helper and install if not found
|
||||
ISAUR=$(command -v yay || command -v paru)
|
||||
if [ -n "$ISAUR" ]; then
|
||||
@@ -33,6 +38,10 @@ else
|
||||
git clone https://aur.archlinux.org/yay-bin.git || { printf "%s - Failed to clone yay from AUR\n" "${ERROR}"; exit 1; }
|
||||
cd yay-bin || { printf "%s - Failed to enter yay-bin directory\n" "${ERROR}"; exit 1; }
|
||||
makepkg -si --noconfirm 2>&1 | tee -a "$LOG" || { printf "%s - Failed to install yay from AUR\n" "${ERROR}"; exit 1; }
|
||||
|
||||
# moving install logs in to Install-Logs folder
|
||||
mv $LOG ../Install-Logs/ || true
|
||||
cd ..
|
||||
fi
|
||||
|
||||
# Update system before proceeding
|
||||
|
||||
Reference in New Issue
Block a user