Worked like a charm. Would be nice to query for a list first of out of date packages first though. Easy enough to tweak the script to do it.
– eduncan911Mar 15 '16 at 16:40

Thank you! Have you tried to get this integrated directly into Homebrew Cask? I just converted it to fish and it works for me as well. It also revealed to me that some old versions were still present after I had installed the current ones.
– PascalMay 1 '16 at 11:55

You need to run brew cask uninstall --force before installing the new version if you do not want the old version to stay there.
– PascalMay 14 '16 at 11:31

@Pascal yeah I noticed I have a lot of old versions stacked here too. Soon I will add uninstall command.
– AtaisMay 16 '16 at 7:23

@Atais does the deinstallation still consistently work for you? Some casks now leave an empty folder with the version number with my script, which messes with the version checking.
– PascalNov 13 '16 at 9:07

Since the homebrew-cask repository is a Homebrew Tap, you'll pull down
the latest Casks every time you issue the regular Homebrew command
brew update. Currently, homebrew-cask cannot always detect if an
Application has been updated. You can force an update via the command
brew cask install --force. We are working on improving this.

The following should be enough to upgrade both brew formulaes and casks.

Here's what I have in my .bash_profile that I run to do a full upgrade pass of homebrew. I "pin" a couple items to keep gigantic downloads from being repeatedly fetched for every update, because their versions are always "latest" or they shouldn't be upgraded.

This isn't very good for users who might have a lot of brew cask installations that require user input (e.g. - quartz). Also, it's not necessary to uninstall every application before re-installing it. Ideally you should also run an update like brew cask update first.
– Danijel-James WApr 29 '16 at 2:00

@Danijel-JamesW Unfortunately it is if you do not want the old version to stay.
– PascalMay 14 '16 at 11:43

I made such script by myself. Please look at the github https://github.com/pesh1983/brew_cask_upgrade. It has pretty good description, but if you have any additional question, feel free to ask me.
It does fair upgrade: uninstall and install, so any necessary cleanup will be performed by 'brew' itself.