fix: guarded homeshick install in an if statement

This commit is contained in:
Kitty Fangs 2024-05-20 05:07:43 +00:00
parent 8eec963c2d
commit d9e42c210f
1 changed files with 15 additions and 12 deletions

View File

@ -15,6 +15,7 @@ for app in git curl; do
done done
## Install homeshick ## Install homeshick
if [[ ! -d $HOME/.homesick ]]; then
git clone https://github.com/andsens/homeshick.git "$HOME/.homesick/repos/homeshick" git clone https://github.com/andsens/homeshick.git "$HOME/.homesick/repos/homeshick"
# shellcheck source=/dev/null # shellcheck source=/dev/null
source "$HOME/.homesick/repos/homeshick/homeshick.sh" source "$HOME/.homesick/repos/homeshick/homeshick.sh"
@ -30,6 +31,8 @@ homeshick --batch clone https://github.com/KitKat31337/homepsick.git
## Link everything ## Link everything
homeshick link --force homeshick link --force
fi
if ! command -v brew &>/dev/null; then if ! command -v brew &>/dev/null; then
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)" /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"