Created
September 7, 2018 12:59
-
-
Save lastguest/84758d2dfd1bb6fe542bf375330a5636 to your computer and use it in GitHub Desktop.
[SHELL] Caffeina provisioner script
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
set +e | |
echo "–––––––––––––––––––––––––––––––––" | |
echo "Caffeina provisioner" | |
echo "–––––––––––––––––––––––––––––––––" | |
echo "We need your password for privileged installation..." | |
sudo -Ei echo 'Thanks.' | |
# Install Homebrew | |
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" </dev/null | |
# Utilities | |
function add_to_dock(){ | |
APP_PATH="$(sed -e 's/[[:space:]]*$//' <<< $(brew cask list $1 | tail -n 1 | cut -d '(' -f 1))" | |
if [ -d "$APP_PATH" ]; then | |
echo "--> Adding $1 to dock as $APP_PATH" | |
defaults write com.apple.dock persistent-apps -array-add "<dict><key>tile-data</key><dict><key>file-data</key><dict><key>_CFURLString</key><string>$APP_PATH</string><key>_CFURLStringType</key><integer>0</integer></dict></dict></dict>" | |
fi | |
} | |
function restart_dock(){ | |
killall Dock | |
} | |
################################ | |
# | |
# COMMON INSTALLATION | |
# | |
################################# | |
packages=( | |
git | |
brew-cask | |
curl | |
wget | |
) | |
casks=( | |
google-chrome | |
sublime-text | |
adobe-acrobat-reader | |
avg-antivirus | |
firefox | |
handbrake | |
imageoptim | |
imagealpha | |
iterm2 | |
vlc | |
google-drive-file-stream | |
lastpass | |
betterzip | |
evernote | |
cyberduck | |
skype | |
spotify | |
) | |
dock_icons=( | |
google-chrome | |
evernote | |
sublime-text | |
spotify | |
) | |
for pkg in ${packages[@]}; do sudo -v; brew install $pkg; done | |
for app in ${casks[@]}; do sudo -v; brew cask install $app; done | |
for app in ${dock_icons[@]}; do sudo -v; add_to_dock $app; done | |
restart_dock | |
# Lastpass | |
echo ">>> Run Lastpass installation" | |
sudo open /usr/local/Caskroom/lastpass/latest/LastPass\ Installer/LastPass\ Installer.app | |
exit | |
# Client Services | |
brew cask install microsoft-office | |
brew cask install box-sync | |
# Creativity | |
brew cask install adobe-creative-cloud | |
brew cask install microsoft-office | |
# UI/UX | |
brew cask install adobe-creative-cloud | |
brew cask install principle | |
brew cask install craftmanager | |
brew cask install handbrake | |
brew cask install nucleo | |
# Tech | |
brew cask install chrome-devtools | |
brew install ngrok | |
brew install bash-completion |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment