diff --git a/installbeta.sh b/installbeta.sh index 5099544..e467aeb 100755 --- a/installbeta.sh +++ b/installbeta.sh @@ -106,9 +106,9 @@ for selection in $CHOICE; do "1") echo "Running zsh setup script..." # Runs local script unless it does not exist or fails - if [[ -f "zsh.sh "]]; then + if [[ -f "zsh.sh" ]]; then echo "Found local script, running..." - bash zsh.sh --skip-watermark; then + bash zsh.sh --skip-watermark else bash "$(curl -fsSL https://raw.githubusercontent.com/alvinlollo/Single-install-script/refs/heads/main/zsh.sh)" --skip-watermark fi @@ -118,7 +118,7 @@ for selection in $CHOICE; do # Runs local script unless it does not exist or fails if [[ -f "LazyVim.sh" ]];then echo "Found local script, running..." - bash LazyVim.sh; then + bash LazyVim.sh else curl -fsSL https://raw.githubusercontent.com/alvinlollo/Single-install-script/refs/heads/main/LazyVim.sh | bash fi @@ -195,7 +195,7 @@ for selection in $CHOICE; do # Runs local script unless it does no exist or fails if [[ -f "./config/PackagesYay.txt" ]]; then echo "Found local config" - cat ./config/PackagesYay.txt | yay -S --needed --save --answerclean None --answerdiff None - --noconfirm; then + cat ./config/PackagesYay.txt | yay -S --needed --save --answerclean None --answerdiff None - --noconfirm elif ! curl -fsSL https://raw.githubusercontent.com/alvinlollo/Single-install-script/refs/heads/main/configs/PackagesYay.txt | yay -S --needed --save --answerclean None --answerdiff None - --noconfirm; then echo "--------------------------------------------------------------------" echo "Failed to install Yay packages. You can try running it manually:" diff --git a/zsh.sh b/zsh.sh index 4d1c540..6f41a02 100755 --- a/zsh.sh +++ b/zsh.sh @@ -96,7 +96,8 @@ set +x # If this user's login shell is already "zsh", do not attempt to switch. if [ "$(basename -- "$SHELL")" = "zsh" ]; then - return + echo "Successfully instaled zsh configuration" + exit 0 # Exit as success fi if command -v chsh >/dev/null; then @@ -121,5 +122,4 @@ else echo "Shell successfully changed to '$zsh'." fi -# Print commands -set -x +echo "Successfully installed zsh" \ No newline at end of file