It'd be great to refactor to support this. If I get time, I'll do it, but that's a big if. https://coderwall.com/p/afmnbq
Hopefully someday Caskfiles will be a thing too. caskroom/homebrew-cask#1946
The Brewfile handles casks natively. Here is a fragment from my own Brewfile.
cask install antirsi
Ah, good to know! I'd still like to see the Homebrew packages refactored to use the Brewfile format though.
Apparently you can split up multiple Brewfiles to organize them also.
$ echo 'install ruby' > Brewfile-ruby
$ echo 'bundle Brewfile-ruby' > Brewfile
$ brew bundle
See comments: https://coderwall.com/p/afmnbq/
My fork/branch is currently very different as I move away from needing Ruby, but the setup is similar (based on Brewfiles).
Bump: my master is closer to yours now, and is using Brewfiles: https://github.com/kevinSuttle/laptop/blob/master/mac-components/Brewfile
What's the upside of using the Brewfile in the case of the laptop script? One downside I see is that the generated mac file is no longer human-readable as a single place to see what gets installed. I have to jump to the Brewfile.
I noticed I have a lot of the things you install that aren't in laptop yet, though!
The casks in particular have some great apps.
The upside for me is encapsulation, but human readability is important for sure. I'm also happy to have all of my binaries and open source artifacts (fonts, QuickLook plugins) in one place. It could be a single point of failure, or a single point of success. :) It's opinionated for sure, but it's also about hopefully encouraging the convention of the Brewfile, like the Gemfile, Makefile, etc.
Gotcha. I definitely agree with you about encouraging the Brewfile convention. I guess I think of it as more project-specific like a Gemfile ("this project needs Postgres, Redis, and ImageMagick) than meant for the whole machine. I think I also prefer the tradeoff of being slightly more explicit in the laptop script than the encapsulation (but I also see your point there).
I'm going to close this issue but it made me want to open #210 to introduce a ~/.laptop.local convention where personalizations can happen. I already stole a bunch of your brew casks into my ~/.laptop.local:
Haha, nice. Thanks Dan.