sous-chefs / homebrew

Development repository for the homebrew cookbook
https://supermarket.chef.io/cookbooks/homebrew
Apache License 2.0
151 stars 136 forks source link
chef chef-cookbook chef-resource hacktoberfest homebrew managed-by-terraform

Homebrew Cookbook

Cookbook Version CI State OpenCollective OpenCollective License

This cookbook installs Homebrew and provides resources for working with taps and casks

Note: The homebrew_tap and homebrew_cask resources shipped in Chef 14.0. When Chef 15.0 is released in April 2019 these resources will be removed from this cookbook as all users should be on 14.0 or later.

Maintainers

This cookbook is maintained by the Sous Chefs. The Sous Chefs are a community of Chef cookbook maintainers working together to maintain important cookbooks. If you’d like to know more please visit sous-chefs.org or come chat with us on the Chef Community Slack in #sous-chefs.

Requirements

Platforms

Chef

Cookbooks

Resources

homebrew_tap

Resource for brew tap, a Homebrew command used to add additional formula repositories. From the brew man page:

brew tap [--full] user/repo [URL]
    Tap a formula repository.

    With URL unspecified, taps a formula repository from GitHub using HTTPS.
    Since so many taps are hosted on GitHub, this command is a shortcut for
    tap user/repo https://github.com/user/homebrew-repo.

    With URL specified, taps a formula repository from anywhere, using
    any transport protocol that git handles. The one-argument form of tap
    simplifies but also limits. This two-argument command makes no
    assumptions, so taps can be cloned from places other than GitHub and
    using protocols other than HTTPS, e.g., SSH, GIT, HTTP, FTP(S), RSYNC.

    By default, the repository is cloned as a shallow copy (--depth=1), but
    if --full is passed, a full clone will be used. To convert a shallow copy
    to a full copy, you can retap passing --full without first untapping.

Default action is :tap which enables the repository. Use :untap to disable a tapped repository.

Actions

Properties

Examples

homebrew_tap 'homebrew/dupes'

homebrew_tap 'homebrew/dupes' do
  action :untap
end

homebrew_tap "Let's install homebrew/dupes" do
  tap_name 'homebrew/dupes'
  url 'https://github.com/homebrew/homebrew-dupes.git'
  full true
end

homebrew_cask

Resource for brew cask, a Homebrew-style CLI workflow for the administration of Mac applications distributed as binaries. It's implemented as a homebrew "external command" called cask.

homebrew-cask on GitHub

Actions

Properties

Examples

homebrew_cask 'google-chrome'

homebrew_cask "Let's remove google-chrome" do
  cask_name 'google-chrome'
  install_cask false
  action :remove
end

View the list of available Casks

Attributes

Usage

We strongly recommend that you put "recipe[homebrew]" in your node's run list, to ensure that it is available on the system and that Homebrew itself gets installed. Putting an explicit dependency in the metadata will cause the cookbook to be downloaded and the library loaded, thus resulting in changing the package provider on macOS, so if you have systems you want to use the default (Mac Ports), they would be changed to Homebrew.

The default recipe also ensures that Homebrew is installed and up to date if the auto-update attribute (above) is true (default).

Contributors

This project exists thanks to all the people who contribute.

Backers

Thank you to all our backers!

https://opencollective.com/sous-chefs#backers

Sponsors

Support this project by becoming a sponsor. Your logo will show up here with a link to your website.

https://opencollective.com/sous-chefs/sponsor/0/website https://opencollective.com/sous-chefs/sponsor/1/website https://opencollective.com/sous-chefs/sponsor/2/website https://opencollective.com/sous-chefs/sponsor/3/website https://opencollective.com/sous-chefs/sponsor/4/website https://opencollective.com/sous-chefs/sponsor/5/website https://opencollective.com/sous-chefs/sponsor/6/website https://opencollective.com/sous-chefs/sponsor/7/website https://opencollective.com/sous-chefs/sponsor/8/website https://opencollective.com/sous-chefs/sponsor/9/website