<commit_before>#!/bin/sh
#
# Homebrew
#
# This installs some of the common dependencies needed (or at least desired)
# using Homebrew.

# Check for Homebrew
if test ! $(which brew)
then
  echo "  Installing Homebrew for you."
  ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" > /tmp/homebrew-install.log
fi

# Homebrew taps
TAPS=(
homebrew/dupes
homebrew/versions
josegonzalez/php
caskroom/cask
caskroom/fonts
caskroom/versions
)

# Homebrew Formulas
FORMULAS=(
zsh
wget
z
git
node
gh
imagemagick
todo-txt
openssl
php54-mcrypt
caskroom/cask/brew-cask
josegonzalez/php/composer
)

# Homebrew casks
CASKS=(
alfred
caffeine
font-inconsolata-dz-for-powerline
font-inconsolata
font-source-code-pro
font-droid-sans-mono
font-meslo-lg
nvalt
firefox
firefox-aurora
firefox-nightly
webkit-nightly
opera
opera-beta
google-chrome
google-chrome-canary
dash
imagealpha
imageoptim
iterm2
sequel-pro
divvy
atom
sublime-text3
the-unarchiver
transmit
vlc
betterzipql
qlcolorcode
qlmarkdown
qlstephen
quicklook-csv
quicklook-json
webp-quicklook
transmission
appcleaner
istat-menus
vmware-fusion
harvest
)

#================================================================================

brew update

brew tap ${TAPS[@]} && brew install ${FORMULAS[@]}

#echo " Changing shell...."
# sudo echo "/usr/local/bin/zsh" >> /etc/shells && chsh -s /usr/local/bin/zsh


# Put everything into system Applications folder
brew cask install --appdir="/Applications" ${CASKS[@]} && brew cask alfred link

# 1Password form the Apple Store needs Chrome to be in /Applications
# Known issues #3
# https://guides.agilebits.com/1password-mac-kb/5/en/topic/browser-validation-failed


echo "Next steps: license paid apps. Install others from App Store."

brew cleanup

exit 0<commit_msg>remove invalid casks. improve homebrew progress output<commit_after>#!/bin/sh
#
# Homebrew
#
# This installs some of the common dependencies needed (or at least desired)
# using Homebrew.

# Check for Homebrew
if test ! $(which brew)
then
  echo "  Installing Homebrew for you."
  ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" > /tmp/homebrew-install.log
fi

# Homebrew taps
TAPS=(
homebrew/dupes
homebrew/versions
josegonzalez/php
caskroom/cask
caskroom/fonts
caskroom/versions
)

# Homebrew Formulas
FORMULAS=(
coreutils
zsh
archey
wget
z
git
#node
gh
imagemagick
todo-txt
openssl
#php54-mcrypt
php56
caskroom/cask/brew-cask
josegonzalez/php/composer
)

# Homebrew casks
CASKS=(
#alfred
caffeine
cd-to
font-inconsolata-dz-for-powerline
font-inconsolata
font-source-code-pro
font-meslo-lg
nvalt
firefox
opera
google-chrome
dash
imagealpha
imageoptim
#iterm2
sequel-pro
#divvy
atom
sublime-text3
the-unarchiver
transmit
vlc
betterzipql
qlcolorcode
qlmarkdown
qlstephen
quicklook-csv
quicklook-json
webp-quicklook
transmission
appcleaner
istat-menus
vmware-fusion
harvest
trim-enabler
drobo-dashboard
)

#================================================================================

echo "Brew update ... "
brew update
echo "Done."

echo "Brew tap & install ... "
brew tap ${TAPS[@]} && brew install ${FORMULAS[@]}
echo "Done."


#echo " Changing shell...."
# sudo echo "/usr/local/bin/zsh" >> /etc/shells && chsh -s /usr/local/bin/zsh

echo "Brew cask install ... "
export HOMEBREW_CASK_OPTS="--appdir=/Applications --caskroom=/etc/Caskroom"
# Put everything into system Applications folder
brew cask install --appdir="/Applications" ${CASKS[@]} && brew cask alfred link
echo "Done."

# 1Password form the Apple Store needs Chrome to be in /Applications
# Known issues #3
# https://guides.agilebits.com/1password-mac-kb/5/en/topic/browser-validation-failed

echo "Brew cleanup ... "
brew cleanup
echo "Done."

echo "Brew cask cleanup ... "
brew cask cleanup
echo "Done."
{'fraction_non_alphanumeric': 0.14698162729658792, 'fraction_numerical': 0.0049868766404199474, 'mean_word_length': 4.748114630467572, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 9, 'https://': 4, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1734090', 'n_tokens_mistral': 1384, 'n_tokens_neox': 1314, 'n_words': 356}