diff --git a/.goreleaser.yml b/.goreleaser.yml index 3e257bce..b9135df4 100644 --- a/.goreleaser.yml +++ b/.goreleaser.yml @@ -37,16 +37,42 @@ changelog: exclude: - '^docs:' - '^test:' -brews: +homebrew_casks: - name: trellis-cli + homepage: https://roots.io/trellis + description: A CLI to manage Trellis projects + caveats: |- + ## Virtualenv + + trellis-cli uses Virtualenv to manage dependencies such as Ansible which it + automatically activates and uses when running any `trellis` command. + But there's still a lot of times you may want to run `ansible-playbook` or `pip` + manually in your shell. To make this experience seamless, trellis-cli offers + shell integration which automatically activates the Virtualenv when you enter a + Trellis project, and deactivates when you leave it. + + To enable this integration, add the following to your shell profile: + + Bash (`~/.bash_profile`): + eval "$(trellis shell-init bash)" + + Zsh (`~/.zshrc`): + eval "$(trellis shell-init zsh)" + + ## Autocompletes + + To install shell completions, run the following: + trellis --autocomplete-install + + It should modify your `.bash_profile`, `.zshrc` or similar. + binaries: + - trellis + hooks: + post: + install: | + if OS.mac? + system_command "/usr/bin/xattr", args: ["-dr", "com.apple.quarantine", "#{staged_path}/trellis"] + end repository: owner: roots name: homebrew-tap - directory: Formula - homepage: https://roots.io/trellis - description: A CLI to manage Trellis projects - install: | - bin.install "trellis" - test: | - system "#{bin}/trellis --autocomplete-install" - system "#{bin}/trellis -v" diff --git a/README.md b/README.md index e7df7da9..11f73bcc 100644 --- a/README.md +++ b/README.md @@ -112,21 +112,7 @@ The following 1 attestation matched the policy criteria ### Autocompletes -Homebrew installs trellis-cli's shell completion automatically by default. If shell completions aren't working, or you installed manually not using Homebrew, you'll need to install the completions manually. - -To use the trellis-cli's autocomplete via Homebrew's shell completion: - -1. Follow Homebrew's install instructions https://docs.brew.sh/Shell-Completion - - Note: For zsh, as the instructions mention, be sure compinit is autoloaded and called, either explicitly or via a framework like oh-my-zsh. - -2. Then run: - - ```bash - brew reinstall trellis-cli - ``` - -To install shell completions manually, run the following: +To install shell completions, run the following: ```bash trellis --autocomplete-install