Skip to content

Commit

Permalink
fix: check if mac apps installed before installation
Browse files Browse the repository at this point in the history
  • Loading branch information
fernandoaleman committed Apr 5, 2024
1 parent dbc30db commit 977edd5
Showing 1 changed file with 11 additions and 7 deletions.
18 changes: 11 additions & 7 deletions mac
Original file line number Diff line number Diff line change
Expand Up @@ -127,15 +127,19 @@ brew "zlib"
# Databases
brew "[email protected]", link: true
brew "libpq", link: true
EOF

# Mac apps
cask "1password"
cask "docker"
cask "google-chrome"
cask "iterm2"
cask "rectangle"
cask "slack"
EOF
apps=(1password docker google-chrome iterm2 rectangle slack)
app_paths=(1Password.app Docker.app "Google Chrome.app" iTerm.app Rectangle.app Slack.app)

for i in "${!apps[@]}"; do
fancy_echo "Installing ${apps[$i]} ..."
if [ ! -d "/Applications/${app_paths[$i]}" ]; then
brew install --cask "${apps[$i]}"
fi
echo "${apps[$i]} installed."
done

if [ ! -d "$HOME/.asdf" ]; then
fancy_echo "Installing asdf version manager ..."
Expand Down

0 comments on commit 977edd5

Please sign in to comment.