language stringclasses 1
value | owner stringlengths 2 15 | repo stringlengths 2 21 | sha stringlengths 45 45 | message stringlengths 7 36.3k | path stringlengths 1 199 | patch stringlengths 15 102k | is_multipart bool 2
classes |
|---|---|---|---|---|---|---|---|
Other | Homebrew | brew | d8afed206fc782a1411f1d9dfb5813caa9167670.json | Use AppleScript to check if GUI apps are running. | Library/Homebrew/cask/artifact/abstract_uninstall.rb | @@ -127,7 +127,7 @@ def running_processes(bundle_id)
# :quit/:signal must come before :kext so the kext will not be in use by a running process
def uninstall_quit(*bundle_ids, command: nil, **_)
bundle_ids.each do |bundle_id|
- next if running_processes(bundle_id).empty?
+ next unless running?(bundle_id)
unless User.current.gui?
opoo "Not logged into a GUI; skipping quitting application ID '#{bundle_id}'."
@@ -146,10 +146,10 @@ def uninstall_quit(*bundle_ids, command: nil, **_)
Kernel.loop do
next unless quit(bundle_id).success?
- if running_processes(bundle_id).empty?
- puts "Application '#{bundle_id}' quit successfully."
- break
- end
+ next if running?(bundle_id)
+
+ puts "Application '#{bundle_id}' quit successfully."
+ break
end
end
rescue Timeout::Error
@@ -159,6 +159,28 @@ def uninstall_quit(*bundle_ids, command: nil, **_)
end
end
+ def running?(bundle_id)
+ script = <<~JAVASCRIPT
+ 'use strict';
+
+ ObjC.import('stdlib')
+
+ function run(argv) {
+ try {
+ var app = Application(argv[0])
+ if (app.running()) {
+ $.exit(0)
+ }
+ } catch (err) { }
+
+ $.exit(1)
+ }
+ JAVASCRIPT
+
+ system_command("osascript", args: ["-l", "JavaScript", "-e", script, bundle_id],
+ print_stderr: true).status.success?
+ end
+
def quit(bundle_id)
script = <<~JAVASCRIPT
'use strict';
@@ -181,8 +203,7 @@ def quit(bundle_id)
JAVASCRIPT
system_command "osascript", args: ["-l", "JavaScript", "-e", script, bundle_id],
- print_stderr: false,
- sudo: true
+ print_stderr: false
end
private :quit
| true |
Other | Homebrew | brew | d8afed206fc782a1411f1d9dfb5813caa9167670.json | Use AppleScript to check if GUI apps are running. | Library/Homebrew/test/cask/artifact/shared_examples/uninstall_zap.rb | @@ -119,7 +119,7 @@
it "is skipped when the user does not have automation access" do
allow(User).to receive(:automation_access?).and_return false
allow(User.current).to receive(:gui?).and_return true
- allow(subject).to receive(:running_processes).with(bundle_id).and_return([[0, "", bundle_id]])
+ allow(subject).to receive(:running?).with(bundle_id).and_return(true)
expect {
subject.public_send(:"#{artifact_dsl_key}_phase", command: fake_system_command)
@@ -128,7 +128,7 @@
it "is skipped when the user is not a GUI user" do
allow(User.current).to receive(:gui?).and_return false
- allow(subject).to receive(:running_processes).with(bundle_id).and_return([[0, "", bundle_id]])
+ allow(subject).to receive(:running?).with(bundle_id).and_return(true)
expect {
subject.public_send(:"#{artifact_dsl_key}_phase", command: fake_system_command)
@@ -139,10 +139,10 @@
allow(User).to receive(:automation_access?).and_return true
allow(User.current).to receive(:gui?).and_return true
- expect(subject).to receive(:running_processes).with(bundle_id).ordered.and_return([[0, "", bundle_id]])
+ expect(subject).to receive(:running?).with(bundle_id).ordered.and_return(true)
expect(subject).to receive(:quit).with(bundle_id)
.and_return(instance_double("SystemCommand::Result", success?: true))
- expect(subject).to receive(:running_processes).with(bundle_id).ordered.and_return([])
+ expect(subject).to receive(:running?).with(bundle_id).ordered.and_return(false)
expect {
subject.public_send(:"#{artifact_dsl_key}_phase", command: fake_system_command)
@@ -153,7 +153,7 @@
allow(User).to receive(:automation_access?).and_return true
allow(User.current).to receive(:gui?).and_return true
- allow(subject).to receive(:running_processes).with(bundle_id).and_return([[0, "", bundle_id]])
+ allow(subject).to receive(:running?).with(bundle_id).and_return(true)
allow(subject).to receive(:quit).with(bundle_id)
.and_return(instance_double("SystemCommand::Result", success?: false))
| true |
Other | Homebrew | brew | 3e46488ca4b564c03a9ead93f27941c457d77a27.json | Display packages to upgrade one package per line | Library/Homebrew/cmd/upgrade.rb | @@ -105,7 +105,7 @@ def upgrade
"#{f.full_specified_name} #{f.pkg_version}"
end
end
- puts formulae_upgrades.join(", ")
+ puts formulae_upgrades.join("\n")
end
return if args.dry_run?
| false |
Other | Homebrew | brew | 2ec526609c321883e0b2349e1a9e51586e6d4345.json | Add link, rename file and remove semicolons | docs/Homebrew-homebrew-core-Merge-Checklist.md | @@ -1,4 +1,4 @@
-# Formula Merge Checklist
+# Homebrew/homebrew-core Merge Checklist
The following checklist is intended to help maintainers to decide on
whether to merge, request changes or close a PR. It also brings more
@@ -18,38 +18,38 @@ This is a more practical checklist, it should be used after you get familiar wit
Check for:
-- previously opened active PRs, we would like to be fair to contributors who came first;
-- patches/`inreplace` that been applied to upstream and can be removed;
-- comments in formula around `url`, we do skip some version (for example [vim](https://github.com/Homebrew/homebrew-core/blob/359dbb190bb3776c4d6a1f603a271dd8f186f077/Formula/vim.rb#L4) or [v8](https://github.com/Homebrew/homebrew-core/blob/359dbb190bb3776c4d6a1f603a271dd8f186f077/Formula/v8.rb#L4));
-- vendored resources that need updates (for example [emscripten](https://github.com/Homebrew/homebrew-core/commit/57126ac765c3ac5201ce53bcdebf7a0e19071eba));
+- previously opened active PRs, we would like to be fair to contributors who came first
+- patches/`inreplace` that been applied to upstream and can be removed
+- comments in formula around `url`, we do skip some version (for example [vim](https://github.com/Homebrew/homebrew-core/blob/359dbb190bb3776c4d6a1f603a271dd8f186f077/Formula/vim.rb#L4) or [v8](https://github.com/Homebrew/homebrew-core/blob/359dbb190bb3776c4d6a1f603a271dd8f186f077/Formula/v8.rb#L4))
+- vendored resources that need updates (for example [emscripten](https://github.com/Homebrew/homebrew-core/commit/57126ac765c3ac5201ce53bcdebf7a0e19071eba))
- vendored dependencies (for example [certbot](https://github.com/Homebrew/homebrew-core/pull/42966/files))
- stable/announced release
- - some teams use odd minor release number for tests and even for stable releases;
- - other teams drop new version with minor release 0 but promote it to stable only after few minor releases;
- - if the software uses only hosted version control (such as github, gitlab or bitbucket), the release should be tagged and if upstream marks latest/pre-releases, PR must use latest;
-- does changelog mention addition/removal of dependency and it's addressed in the PR;
- - does formula depend on versioned formula (for example `python@2`, `go@1.10`, `erlang@17`) that can be upgraded;
+ - some teams use odd minor release number for tests and even for stable releases
+ - other teams drop new version with minor release 0 but promote it to stable only after few minor releases
+ - if the software uses only hosted version control (such as github, gitlab or bitbucket), the release should be tagged and if upstream marks latest/pre-releases, PR must use latest
+- does changelog mention addition/removal of dependency and it's addressed in the PR
+ - does formula depend on versioned formula (for example `python@2`, `go@1.10`, `erlang@17`) that can be upgraded
- commits
- - contain one formula change per commit;
+ - contain one formula change per commit
- version update follows preferred message format for simple version updates `foobar 7.3`
- other fixes format is `foobar: fix flibble matrix`
- - you can use `--bump` flag for `brew pull` in case PR have single commit but the wrong message.
-- bottle block is not removed;
+ - you can use `--bump` flag for `brew pull` in case PR have single commit but the wrong message
+- bottle block is not removed
Suggested reply:
```
Please keep bottle block in place, [@BrewTestBot](https://github.com/BrewTestBot) takes care of it.
```
-- is there are test block for other than checking version or printing help? Consider asking to add one;
+- is there are test block for other than checking version or printing help? Consider asking to add one
- if CI failed
- - due to test block - paste relevant lines and add `test failure` label;
- - due to build errors - paste relevant lines and add `build failure` label;
+ - due to test block - paste relevant lines and add `test failure` label
+ - due to build errors - paste relevant lines and add `build failure` label
- due to other formulas need revision bumps - suggest to use the following command:
```
# in this example PR is for `libuv` formula and `urbit` needs revision bump
brew bump-revision --message 'for libuv' urbit
```
-- if CI is green and formula `bottle :unneeded` you can merge it through GitHub UI;
+- if CI is green and formula `bottle :unneeded` you can merge it through GitHub UI
- if CI is green and bottles need to be pulled, use: `brew pull --bottle $PR_ID`
- don't forget to thank the contributor
- celebrate the first-time contributors
-- suggest to use `brew bump-formula-pr` next time if this was not a case;
+- suggest to use `brew bump-formula-pr` next time if this was not a case | true |
Other | Homebrew | brew | 2ec526609c321883e0b2349e1a9e51586e6d4345.json | Add link, rename file and remove semicolons | docs/README.md | @@ -51,6 +51,7 @@
- [Common Issues for Maintainers](Common-Issues-for-Core-Contributors.md)
- [Releases](Releases.md)
- [Developer/Internal API Documentation](https://rubydoc.brew.sh)
+- [Homebrew/homebrew-core merge checklist](Homebrew-homebrew-core-Merge-Checklist.md)
## Governance
| true |
Other | Homebrew | brew | 4b30a6173224a51342c71a680b3c59ecdebefbb9.json | prof: use ruby-prof 0.18.0
This is the newest version that works with Ruby 2.3.
Also, update the `.gitignore` to hide it while we're here. | .gitignore | @@ -134,6 +134,7 @@
**/vendor/bundle/ruby/*/gems/rspec-support-*/
**/vendor/bundle/ruby/*/gems/rspec-wait-*/
**/vendor/bundle/ruby/*/gems/rubocop-0*/
+**/vendor/bundle/ruby/*/gems/ruby-prof-*/
**/vendor/bundle/ruby/*/gems/ruby-progressbar-*/
**/vendor/bundle/ruby/*/gems/simplecov-*/
**/vendor/bundle/ruby/*/gems/simplecov-cobertura-*/ | true |
Other | Homebrew | brew | 4b30a6173224a51342c71a680b3c59ecdebefbb9.json | prof: use ruby-prof 0.18.0
This is the newest version that works with Ruby 2.3.
Also, update the `.gitignore` to hide it while we're here. | Library/Homebrew/dev-cmd/prof.rb | @@ -18,7 +18,7 @@ def prof_args
def prof
prof_args.parse
- Homebrew.install_gem_setup_path! "ruby-prof"
+ Homebrew.install_gem_setup_path! "ruby-prof", version: "0.18.0"
FileUtils.mkdir_p "prof"
brew_rb = (HOMEBREW_LIBRARY_PATH/"brew.rb").resolved_path
safe_system "ruby-prof", "--printer=multi", "--file=prof", brew_rb, "--", *ARGV | true |
Other | Homebrew | brew | 4e2096f21a68fd3f95248cd5a0482fdff112e146.json | Add cask completions to `brew cleanup` | completions/fish/brew.fish | @@ -253,6 +253,7 @@ __fish_brew_complete_arg 'cat' -a '(__fish_brew_suggest_formulae_all)'
__fish_brew_complete_cmd 'cleanup' "Remove old installed versions"
__fish_brew_complete_arg 'cleanup' -a '(__fish_brew_suggest_formulae_installed)'
+__fish_brew_complete_arg 'cleanup' -a '(__fish_brew_suggest_casks_installed)'
__fish_brew_complete_arg 'cleanup' -l prune -d "Remove all cache files older than given number of days" -a '(seq 1 5)'
__fish_brew_complete_arg 'cleanup' -s n -l dry-run -d "Show what files would be removed"
__fish_brew_complete_arg 'cleanup' -s s -d "Scrub the cache, removing downloads for even the latest versions of formulae" | false |
Other | Homebrew | brew | f2a4681f26154363b1b62a204319ca549d48a310.json | workflows/apidoc: combine steps to preserve current directory | .github/workflows/apidoc.yml | @@ -17,7 +17,7 @@ jobs:
with:
version: '>=2.3'
- - name: Set up repositories
+ - name: Build and push API docs
run: |
# clone rubydoc.brew.sh with SSH so we can push back
git clone git@github.com:Homebrew/rubydoc.brew.sh
@@ -26,18 +26,9 @@ jobs:
# clone latest Homebrew/brew
git clone --depth=1 https://github.com/Homebrew/brew
- - name: Install RubyGems
- run: |
- # silence bundler complaining about being root
- mkdir ~/.bundle
- echo 'BUNDLE_SILENCE_ROOT_WARNING: "1"' > ~/.bundle/config
-
+ # run rake to build documentation
gem install bundler
bundle install --jobs 4 --retry 3
-
- - name: Build and push API docs
- run: |
- # run rake to build documentation
bundle exec rake
# commit and push generated files | false |
Other | Homebrew | brew | 4add1d1cb35ececf8823e2400a424254a44660ac.json | Check binary URL resources with RuboCop
- Migrate the existing binary URL audit to a RuboCop.
- Check resources as well as main URLs
- Also check for "macos" and "osx" in URLs
- Add whitelists for URLs and formulae | Library/Homebrew/dev-cmd/audit.rb | @@ -920,18 +920,6 @@ def audit_prefix_has_contents
EOS
end
- def audit_url_is_not_binary
- return unless @core_tap
-
- urls = @specs.map(&:url)
-
- urls.each do |url|
- if url =~ /darwin/i && (url =~ /x86_64/i || url =~ /amd64/i)
- problem "#{url} looks like a binary package, not a source archive. The `core` tap is source-only."
- end
- end
- end
-
def quote_dep(dep)
dep.is_a?(Symbol) ? dep.inspect : "'#{dep}'"
end | true |
Other | Homebrew | brew | 4add1d1cb35ececf8823e2400a424254a44660ac.json | Check binary URL resources with RuboCop
- Migrate the existing binary URL audit to a RuboCop.
- Check resources as well as main URLs
- Also check for "macos" and "osx" in URLs
- Add whitelists for URLs and formulae | Library/Homebrew/rubocops/urls.rb | @@ -7,6 +7,28 @@ module Cop
module FormulaAudit
# This cop audits URLs and mirrors in Formulae.
class Urls < FormulaCop
+ # These are formulae that, sadly, require an upstream binary to bootstrap.
+ BINARY_FORMULA_URLS_WHITELIST = %w[
+ crystal
+ fpc
+ ghc
+ ghc@8.2
+ go
+ go@1.9
+ go@1.10
+ go@1.11
+ haskell-stack
+ ldc
+ mlton
+ rust
+ ].freeze
+
+ # specific rust-nightly temporarily acceptable until a newer version is released.
+ # DO NOT RE-ADD A NEWER RUST-NIGHTLY IN FUTURE.
+ BINARY_URLS_WHITELIST = %w[
+ https://static.rust-lang.org/dist/2019-08-24/rust-nightly-x86_64-apple-darwin.tar.xz
+ ].freeze
+
def audit_formula(_node, _class_node, _parent_class_node, body_node)
urls = find_every_func_call_by_name(body_node, :url)
mirrors = find_every_func_call_by_name(body_node, :mirror)
@@ -202,6 +224,18 @@ def audit_formula(_node, _class_node, _parent_class_node, body_node)
audit_urls(urls, maven_pattern) do |match, url|
problem "#{url} should be `https://search.maven.org/remotecontent?filepath=#{match[1]}`"
end
+
+ return if formula_tap != "homebrew-core"
+
+ # Check for binary URLs
+ audit_urls(urls, /(darwin|macos|osx)/i) do |_, url|
+ next if url !~ /x86_64/i && url !~ /amd64/i
+ next if BINARY_FORMULA_URLS_WHITELIST.include?(@formula_name)
+ next if BINARY_URLS_WHITELIST.include?(url)
+
+ problem "#{url} looks like a binary package, not a source archive. " \
+ "Homebrew/homebrew-core is source-only."
+ end
end
end
| true |
Other | Homebrew | brew | 4add1d1cb35ececf8823e2400a424254a44660ac.json | Check binary URL resources with RuboCop
- Migrate the existing binary URL audit to a RuboCop.
- Check resources as well as main URLs
- Also check for "macos" and "osx" in URLs
- Add whitelists for URLs and formulae | Library/Homebrew/test/dev-cmd/audit_spec.rb | @@ -530,84 +530,6 @@ def formula_gsub_commit(before, after = "")
end
end
- describe "#audit_url_is_not_binary" do
- specify "it detects a url containing darwin and x86_64" do
- fa = formula_auditor "foo", <<~RUBY, core_tap: true
- class Foo < Formula
- url "https://brew.sh/example-darwin.x86_64.tar.gz"
- end
- RUBY
-
- fa.audit_url_is_not_binary
-
- expect(fa.problems.first)
- .to match("looks like a binary package, not a source archive. The `core` tap is source-only.")
- end
-
- specify "it detects a url containing darwin and amd64" do
- fa = formula_auditor "foo", <<~RUBY, core_tap: true
- class Foo < Formula
- url "https://brew.sh/example-darwin.amd64.tar.gz"
- end
- RUBY
-
- fa.audit_url_is_not_binary
-
- expect(fa.problems.first)
- .to match("looks like a binary package, not a source archive. The `core` tap is source-only.")
- end
-
- specify "it works on the devel spec" do
- fa = formula_auditor "foo", <<~RUBY, core_tap: true
- class Foo < Formula
- url "https://brew.sh/valid-1.0.tar.gz"
-
- devel do
- url "https://brew.sh/example-darwin.x86_64.tar.gz"
- end
- end
- RUBY
-
- fa.audit_url_is_not_binary
-
- expect(fa.problems.first)
- .to match("looks like a binary package, not a source archive. The `core` tap is source-only.")
- end
-
- specify "it works on the head spec" do
- fa = formula_auditor "foo", <<~RUBY, core_tap: true
- class Foo < Formula
- url "https://brew.sh/valid-1.0.tar.gz"
-
- head do
- url "https://brew.sh/example-darwin.x86_64.tar.gz"
- end
- end
- RUBY
-
- fa.audit_url_is_not_binary
-
- expect(fa.problems.first)
- .to match("looks like a binary package, not a source archive. The `core` tap is source-only.")
- end
-
- specify "it ignores resource urls" do
- fa = formula_auditor "foo", <<~RUBY, core_tap: true
- class Foo < Formula
- url "https://brew.sh/valid-1.0.tar.gz"
-
- resource "binary_res" do
- url "https://brew.sh/example-darwin.x86_64.tar.gz"
- end
- end
- RUBY
-
- fa.audit_url_is_not_binary
-
- expect(fa.problems).to eq([])
- end
- end
-
describe "#audit_versioned_keg_only" do
specify "it warns when a versioned formula is not `keg_only`" do
fa = formula_auditor "foo@1.1", <<~RUBY, core_tap: true | true |
Other | Homebrew | brew | 4add1d1cb35ececf8823e2400a424254a44660ac.json | Check binary URL resources with RuboCop
- Migrate the existing binary URL audit to a RuboCop.
- Check resources as well as main URLs
- Also check for "macos" and "osx" in URLs
- Add whitelists for URLs and formulae | Library/Homebrew/test/rubocops/urls_spec.rb | @@ -142,12 +142,26 @@
"msg" => "https://central.maven.org/maven2/com/bar/foo/1.1/foo-1.1.jar should be " \
"`https://search.maven.org/remotecontent?filepath=com/bar/foo/1.1/foo-1.1.jar`",
"col" => 2,
+ }, {
+ "url" => "https://brew.sh/example-darwin.x86_64.tar.gz",
+ "msg" => "https://brew.sh/example-darwin.x86_64.tar.gz looks like a binary package, " \
+ "not a source archive. Homebrew/homebrew-core is source-only.",
+ "col" => 2,
+ "formula_tap" => "homebrew-core",
+ }, {
+ "url" => "https://brew.sh/example-darwin.amd64.tar.gz",
+ "msg" => "https://brew.sh/example-darwin.amd64.tar.gz looks like a binary package, " \
+ "not a source archive. Homebrew/homebrew-core is source-only.",
+ "col" => 2,
+ "formula_tap" => "homebrew-core",
}]
}
context "When auditing urls" do
it "with offenses" do
formulae.each do |formula|
+ allow_any_instance_of(RuboCop::Cop::FormulaCop).to receive(:formula_tap)
+ .and_return(formula["formula_tap"])
source = <<~RUBY
class Foo < Formula
desc "foo" | true |
Other | Homebrew | brew | c34b4c3abd0654733a072df5efbfafb04e1d8d4f.json | MacOSRequirement: add to_json method | Library/Homebrew/requirements/macos_requirement.rb | @@ -42,11 +42,11 @@ def message(type: :formula)
versions newer than #{@version.pretty_name} due to an upstream incompatibility.
EOS
when :cask
- "This cask does not on macOS versions newer than #{@version.pretty_name}."
+ "This cask does not run on macOS versions newer than #{@version.pretty_name}."
end
else
if @version.respond_to?(:to_ary)
- *versions, last = @version.map(:pretty_name)
+ *versions, last = @version.map(&:pretty_name)
return "macOS #{versions.join(", ")} or #{last} is required."
end
@@ -59,4 +59,11 @@ def display_s
"macOS #{@comparator} #{@version}"
end
+
+ def to_json(*args)
+ comp = @comparator.to_s
+ return { comp => @version.map(&:to_s) }.to_json(*args) if @version.is_a?(Array)
+
+ { comp => [@version.to_s] }.to_json(*args)
+ end
end | false |
Other | Homebrew | brew | 22a7b4bc1e51e3fd32e9916bed25fcd45f178ff8.json | python_virtualenv_constants: upgrade virtualenv to 16.7.4 | Library/Homebrew/language/python_virtualenv_constants.rb | @@ -1,8 +1,8 @@
# frozen_string_literal: true
PYTHON_VIRTUALENV_URL =
- "https://files.pythonhosted.org/packages/a9/8a" \
- "/580c7176f01540615c2eb3f3ab5462613b4beac4aa63410be89ecc7b7472" \
- "/virtualenv-16.7.2.tar.gz"
+ "https://files.pythonhosted.org/packages/11/74" \
+ "/2c151a13ef41ab9fb43b3c4ff9e788e0496ed7923b2078d42cab30622bdf" \
+ "/virtualenv-16.7.4.tar.gz"
PYTHON_VIRTUALENV_SHA256 =
- "909fe0d3f7c9151b2df0a2cb53e55bdb7b0d61469353ff7a49fd47b0f0ab9285"
+ "94a6898293d07f84a98add34c4df900f8ec64a570292279f6d91c781d37fd305" | false |
Other | Homebrew | brew | 82e314c4674598552ad7f469377b47772ca64a05.json | messages_spec: handle frozen Homebrew.args.
This is an order dependent test failure fix as seen in
https://travis-ci.org/Homebrew/homebrew-test-bot/builds/574559080 | Library/Homebrew/test/messages_spec.rb | @@ -72,9 +72,11 @@
end
end
+ # Homebrew.args OpenStruct usage cannot use verified doubles.
+ # rubocop:disable RSpec/VerifiedDoubles
context "when the --display-times argument is present" do
before do
- allow(Homebrew.args).to receive(:display_times?).and_return(true)
+ allow(Homebrew).to receive(:args).and_return(double(display_times?: true))
end
context "when install_times is empty" do
@@ -101,12 +103,13 @@
context "when the --display-times argument isn't present" do
before do
- allow(ARGV).to receive(:include?).with("--display-times").and_return(false)
+ allow(Homebrew).to receive(:args).and_return(double(display_times?: false))
end
it "doesn't print installation times" do
expect { messages.display_messages }.not_to output.to_stdout
end
end
+ # rubocop:enable RSpec/VerifiedDoubles
end
end | false |
Other | Homebrew | brew | 3ed9b35f7099e8557ad75983a42686597379c74f.json | man: allow multi-line paragraphs for comment-based docs | Library/Homebrew/dev-cmd/man.rb | @@ -196,8 +196,11 @@ def cmd_comment_manpage_lines(cmd_path)
lines = [format_usage_banner(comment_lines.first).chomp]
comment_lines.slice(1..-1)
.each do |line|
- line = line.slice(4..-1)
- next unless line
+ line = line.slice(4..-2)
+ unless line
+ lines.last << "\n"
+ next
+ end
# Omit the common global_options documented separately in the man page.
next if line =~ /--(debug|force|help|quiet|verbose) /
@@ -206,6 +209,7 @@ def cmd_comment_manpage_lines(cmd_path)
lines << line.gsub(/^ +(-+[a-z-]+), (-+[a-z-]+) +/, "* `\\1`, `\\2`:\n ")
.gsub(/^ +(-+[a-z-]+) +/, "* `\\1`:\n ")
end
+ lines.last << "\n"
lines
end
| true |
Other | Homebrew | brew | 3ed9b35f7099e8557ad75983a42686597379c74f.json | man: allow multi-line paragraphs for comment-based docs | docs/Manpage.md | @@ -423,11 +423,11 @@ build systems would not find otherwise.
Use the standard `PATH` instead of superenv's when `std` is passed.
### `shellenv`
+
Print export statements. When run in a shell, this installation of Homebrew will be added to your `PATH`, `MANPATH`, and `INFOPATH`.
The variables `HOMEBREW_PREFIX`, `HOMEBREW_CELLAR` and `HOMEBREW_REPOSITORY` are also exported to avoid querying them multiple times.
-
-Consider adding evaluation of this command's output to your dotfiles (e.g. `~/.profile`) with: `eval $(brew shellenv)`
+Consider adding evaluation of this command's output to your dotfiles (e.g. `~/.profile` or `~/.zprofile`) with: `eval $(brew shellenv)`
### `style` [*`options`*] [*`file`*|*`tap`*|*`formula`*]
@@ -527,12 +527,14 @@ also `pin`.
Remove a tapped formula repository.
### `update`, `up` [*`options`*]
+
Fetch the newest version of Homebrew and all formulae from GitHub using `git`(1) and perform any necessary migrations.
* `--merge`:
Use `git merge` to apply updates (rather than `git rebase`).
### `update-reset` [*`repository`*]
+
Fetch and reset Homebrew and all tap repositories (or any specified *`repository`*) using `git`(1) to their latest `origin/master`.
*Note:* this will destroy all your uncommitted or committed changes. | true |
Other | Homebrew | brew | 3ed9b35f7099e8557ad75983a42686597379c74f.json | man: allow multi-line paragraphs for comment-based docs | manpages/brew.1 | @@ -530,10 +530,7 @@ Use the standard \fBPATH\fR instead of superenv\'s when \fBstd\fR is passed\.
Print export statements\. When run in a shell, this installation of Homebrew will be added to your \fBPATH\fR, \fBMANPATH\fR, and \fBINFOPATH\fR\.
.
.P
-The variables \fBHOMEBREW_PREFIX\fR, \fBHOMEBREW_CELLAR\fR and \fBHOMEBREW_REPOSITORY\fR are also exported to avoid querying them multiple times\.
-.
-.P
-Consider adding evaluation of this command\'s output to your dotfiles (e\.g\. \fB~/\.profile\fR) with: \fBeval $(brew shellenv)\fR
+The variables \fBHOMEBREW_PREFIX\fR, \fBHOMEBREW_CELLAR\fR and \fBHOMEBREW_REPOSITORY\fR are also exported to avoid querying them multiple times\. Consider adding evaluation of this command\'s output to your dotfiles (e\.g\. \fB~/\.profile\fR or \fB~/\.zprofile\fR) with: \fBeval $(brew shellenv)\fR
.
.SS "\fBstyle\fR [\fIoptions\fR] [\fIfile\fR|\fItap\fR|\fIformula\fR]"
Check formulae or files for conformance to Homebrew style guidelines\. | true |
Other | Homebrew | brew | 20e3edfc780f6ca096e5d762a73abbf3182f0eda.json | manpages: add link to API & regenerate | Library/Homebrew/manpages/brew.1.md.erb | @@ -326,6 +326,8 @@ And for an authenticated HTTP proxy:
Homebrew Documentation: <https://docs.brew.sh>
+Homebrew API: <https://rubydoc.brew.sh>
+
`brew-cask`(1), `git`(1), `git-log`(1)
## AUTHORS | true |
Other | Homebrew | brew | 20e3edfc780f6ca096e5d762a73abbf3182f0eda.json | manpages: add link to API & regenerate | docs/Manpage.md | @@ -15,13 +15,16 @@ didn't include with macOS.
For the full command list, see the [COMMANDS](#commands) section.
-With `--verbose` or `-v`, many commands print extra debugging information. Note that
-these flags should only appear after a command.
+With `--verbose` or `--debug`, many commands print extra debugging information. Note that
+these options should only appear after a command.
### `install` *`formula`*:
Install *`formula`*.
+*`formula`* is usually the name of the formula to install, but it has other syntaxes which
+are listed in the [SPECIFYING FORMULAE](#specifying-formulae) section.
+
### `uninstall` *`formula`*:
Uninstall *`formula`*.
@@ -31,31 +34,33 @@ Uninstall *`formula`*.
List all installed formulae.
### `search` (*`text`*|`/`*`text`*`/`):
+
Perform a substring search of cask tokens and formula names for *`text`*. If *`text`*
-is surrounded with slashes, then it is interpreted as a regular expression.
+is flanked by slashes, it is interpreted as a regular expression.
The search for *`text`* is extended online to `homebrew/core` and `homebrew/cask`.
-If no search term is given, all locally available formulae are listed.
+If no search term is provided, all locally available formulae are listed.
## COMMANDS
-### `analytics` [`on`|`off`|`state`|`regenerate-uuid`]
+### `analytics` [*`subcommand`*]
If `on` or `off` is passed, turn Homebrew's analytics on or off respectively.
-If `state` is passed, display anonymous user behaviour analytics state. Read
-more at <https://docs.brew.sh/Analytics>.
+If `state` is passed, display the current anonymous user behaviour analytics
+state. Read more at <https://docs.brew.sh/Analytics>.
-If `regenerate-uuid` is passed, regenerate UUID used in Homebrew's analytics.
+If `regenerate-uuid` is passed, regenerate the UUID used in Homebrew's
+analytics.
### `cat` *`formula`*
Display the source of *`formula`*.
### `cleanup` [*`options`*] [*`formula`*|*`cask`*]
-Remove stale lock files and outdated downloads for formulae and casks, and
+Remove stale lock files and outdated downloads for all formulae and casks, and
remove old versions of installed formulae. If arguments are specified, only do
-this for the specified formulae and casks.
+this for the given formulae and casks.
* `--prune`:
Remove all cache files older than specified *`days`*.
@@ -68,28 +73,28 @@ this for the specified formulae and casks.
### `command` *`cmd`*
-Display the path to the file which is used when invoking `brew` *`cmd`*.
+Display the path to the file being used when invoking `brew` *`cmd`*.
### `commands` [*`options`*]
-Show a list of built-in and external commands.
+Show lists of built-in and external commands.
* `--include-aliases`:
- Include the aliases of internal commands.
+ Include aliases of internal commands.
### `config`
-Show Homebrew and system configuration useful for debugging. If you file a bug
-report, you will likely be asked for this information if you do not provide it.
+Show Homebrew and system configuration info useful for debugging. If you file a
+bug report, you will be required to provide this information.
-### `deps` [*`options`*] *`formula`*
+### `deps` [*`options`*] [*`formula`*]
Show dependencies for *`formula`*. Additional options specific to *`formula`* may be
appended to the command. When given multiple formula arguments, show the
intersection of dependencies for each formula.
* `-n`:
- Show dependencies in topological order.
+ Sort dependencies in topological order.
* `--1`:
Only show dependencies one level down, instead of recursing.
* `--union`:
@@ -115,7 +120,7 @@ intersection of dependencies for each formula.
* `--all`:
List dependencies for all available formulae.
* `--for-each`:
- Switch into the mode used by the `--all` option, but only list dependencies for the specified *`formula`*, one formula per line. This is used for debugging the `--installed`/`--all` display mode.
+ Switch into the mode used by the `--all` option, but only list dependencies for each provided *`formula`*, one formula per line. This is used for debugging the `--installed`/`--all` display mode.
### `desc` [*`options`*] (*`text`*|`/`*`text`*`/`|*`formula`*)
@@ -124,11 +129,11 @@ cached; the cache is created on the first search, making that search slower than
subsequent ones.
* `-s`, `--search`:
- Search both name and description for provided *`text`*. If *`text`* is flanked by slashes, it is interpreted as a regular expression.
+ Search both names and descriptions for *`text`*. If *`text`* is flanked by slashes, it is interpreted as a regular expression.
* `-n`, `--name`:
- Search just the names for provided *`text`*. If *`text`* is flanked by slashes, it is interpreted as a regular expression.
+ Search just names for *`text`*. If *`text`* is flanked by slashes, it is interpreted as a regular expression.
* `-d`, `--description`:
- Search just the descriptions for provided *`text`*. If *`text`* is flanked by slashes, it is interpreted as a regular expression.
+ Search just descriptions for *`text`*. If *`text`* is flanked by slashes, it is interpreted as a regular expression.
### `diy` [*`options`*]
@@ -137,13 +142,13 @@ the output from this command, you can install your own software into the Cellar
and then link it into Homebrew's prefix with `brew link`.
* `--name`:
- Explicitly set the provided *`name`* of the package being installed.
+ Explicitly set the *`name`* of the package being installed.
* `--version`:
- Explicitly set the provided *`version`* of the package being installed.
+ Explicitly set the *`version`* of the package being installed.
### `doctor` [*`options`*]
-Check your system for potential problems. Doctor exits with a non-zero status if
+Check your system for potential problems. Will exit with a non-zero status if
any potential problems are found. Please note that these warnings are just used
to help the Homebrew maintainers with debugging if you file an issue. If
everything you use Homebrew for is working fine: please don't worry or file an
@@ -156,59 +161,55 @@ issue; just ignore this.
### `fetch` [*`options`*] *`formula`*
-Download the source packages for the given *`formula`*. For tarballs, also print
-SHA-256 checksums.
+Download a bottle (if available) or source packages for *`formula`*. For tarballs,
+also print SHA-256 checksums.
* `--HEAD`:
Fetch HEAD version instead of stable version.
* `--devel`:
Fetch development version instead of stable version.
* `--retry`:
- Retry if a download fails or re-download if the checksum of a previously cached version no longer matches.
+ Retry if downloading fails or re-download if the checksum of a previously cached version no longer matches.
* `--deps`:
- Download dependencies for any listed *`formula`*.
+ Also download dependencies for any listed *`formula`*.
* `-s`, `--build-from-source`:
- Download the source for rather than a bottle.
+ Download source packages rather than a bottle.
* `--build-bottle`:
- Download the source (for eventual bottling) rather than a bottle.
+ Download source packages (for eventual bottling) rather than a bottle.
* `--force-bottle`:
Download a bottle if it exists for the current or newest version of macOS, even if it would not be used during installation.
### `gist-logs` [*`options`*] *`formula`*
-Upload logs for a failed build of *`formula`* to a new Gist.
-
-*`formula`* is usually the name of the formula to install, but it can be specified
-in several different ways.
-
-If no logs are found, an error message is presented.
+Upload logs for a failed build of *`formula`* to a new Gist. Presents an error
+message if no logs are found.
* `--with-hostname`:
Include the hostname in the Gist.
* `-n`, `--new-issue`:
- Automatically create a new issue in the appropriate GitHub repository as well as creating the Gist.
+ Automatically create a new issue in the appropriate GitHub repository after creating the Gist.
* `-p`, `--private`:
- The Gist will be marked private and will not appear in listings but will be accessible with the link.
+ The Gist will be marked private and will not appear in listings but will be accessible with its link.
### `home` [*`formula`*]
-Open *`formula`*'s homepage in a browser. If no formula is provided, open
-Homebrew's own homepage in a browser.
+Open *`formula`*'s homepage in a browser, or open Homebrew's own homepage if no
+formula is provided.
### `info` [*`options`*] [*`formula`*]
Display brief statistics for your Homebrew installation.
-If *`formula`* is specified, show summary of information about *`formula`*.
+If *`formula`* is provided, show summary of information about *`formula`*.
* `--analytics`:
- Display global Homebrew analytics data or, if specified, installation and build error data for *`formula`* (provided neither `HOMEBREW_NO_ANALYTICS` nor `HOMEBREW_NO_GITHUB_API` are set).
+ List global Homebrew analytics data or, if specified, installation and build error data for *`formula`* (provided neither `HOMEBREW_NO_ANALYTICS` nor `HOMEBREW_NO_GITHUB_API` are set).
* `--days`:
How many days of global analytics data to retrieve. The value for *`days`* must be `30`, `90` or `365`. The default is `30`.
* `--category`:
Which type of global analytics data to retrieve. The value for *`category`* must be `install`, `install-on-request`, `cask-install`, `build-error` or `os-version`. The default is `install`.
* `--github`:
- Open a browser to the GitHub source page for *`formula`*. To view formula history locally: `brew log -p` *`formula`*
+ Open the GitHub source page for *`formula`* in a browser. To view formula history locally: `brew log -p` *`formula`*
* `--json`:
Print a JSON representation of *`formula`*. Currently the default and only accepted value for *`version`* is `v1`. See the docs for examples of using the JSON output: <https://docs.brew.sh/Querying-Brew>
* `--installed`:
@@ -218,40 +219,38 @@ If *`formula`* is specified, show summary of information about *`formula`*.
### `install` [*`options`*] *`formula`*
-Install *`formula`*.
-
-*`formula`* is usually the name of the formula to install, but it can be specified
-in several different ways.
+Install *`formula`*. Additional options specific to *`formula`* may be appended to
+the command.
-Unless `HOMEBREW_NO_INSTALL_CLEANUP` is set, `brew cleanup` will be run for the
-installed formulae or, every 30 days, for all formulae.
+Unless `HOMEBREW_NO_INSTALL_CLEANUP` is set, `brew cleanup` will then be run for
+the installed formulae or, every 30 days, for all formulae.
* `--env`:
- If `std` is passed, use the standard build environment instead of superenv.If `super` is passed, use superenv even if the formula specifies the standard build environment.
+ If `std` is passed, use the standard build environment instead of superenv. If `super` is passed, use superenv even if the formula specifies the standard build environment.
* `--ignore-dependencies`:
An unsupported Homebrew development flag to skip installing any dependencies of any kind. If the dependencies are not already present, the formula will have issues. If you're not developing Homebrew, consider adjusting your PATH rather than using this flag.
* `--only-dependencies`:
- Install the dependencies with specified options but do not install the specified formula.
+ Install the dependencies with specified options but do not install the formula itself.
* `--cc`:
- Attempt to compile using provided *`compiler`*. *`compiler`* should be the name of the compiler's executable, for instance `gcc-7` for GCC 7. In order to use LLVM's clang, use `llvm_clang`. To specify the Apple-provided clang, use `clang`. This parameter will only accept compilers that are provided by Homebrew or bundled with macOS. Please do not file issues if you encounter errors while using this flag.
+ Attempt to compile using the specified *`compiler`*, which should be the name of the compiler's executable, e.g. `gcc-7` for GCC 7. In order to use LLVM's clang, specify `llvm_clang`. To use the Apple-provided clang, specify `clang`. This option will only accept compilers that are provided by Homebrew or bundled with macOS. Please do not file issues if you encounter errors while using this option.
* `-s`, `--build-from-source`:
- Compile the specified *`formula`* from source even if a bottle is provided. Dependencies will still be installed from bottles if they are available.
+ Compile *`formula`* from source even if a bottle is provided. Dependencies will still be installed from bottles if they are available.
* `--force-bottle`:
Install from a bottle if it exists for the current or newest version of macOS, even if it would not normally be used for installation.
* `--include-test`:
- Install testing dependencies required to run `brew test`.
+ Install testing dependencies required to run `brew test` *`formula`*.
* `--devel`:
If *`formula`* defines it, install the development version.
* `--HEAD`:
If *`formula`* defines it, install the HEAD version, aka. master, trunk, unstable.
* `--fetch-HEAD`:
- Fetch the upstream repository to detect if the HEAD installation of the formula is outdated. Otherwise, the repository's HEAD will be checked for updates when a new stable or development version has been released.
+ Fetch the upstream repository to detect if the HEAD installation of the formula is outdated. Otherwise, the repository's HEAD will only be checked for updates when a new stable or development version has been released.
* `--keep-tmp`:
- Don't delete the temporary files created during installation.
+ Retain the temporary files created during installation.
* `--build-bottle`:
- Prepare the formula for eventual bottling during installation.
+ Prepare the formula for eventual bottling during installation, skipping any post-install steps.
* `--bottle-arch`:
- Optimise bottles for the given architecture rather than the oldest architecture supported by the version of macOS the bottles are built on.
+ Optimise bottles for the specified architecture rather than the oldest architecture supported by the version of macOS the bottles are built on.
* `--display-times`:
Print install times for each formula at the end of the run.
* `-i`, `--interactive`:
@@ -261,91 +260,92 @@ installed formulae or, every 30 days, for all formulae.
### `leaves`
-Show installed formulae that are not dependencies of another installed formula.
+List installed formulae that are not dependencies of another installed formula.
-### `ln`, `link` [*`options`*] *`formula`*
+### `link`, `ln` [*`options`*] *`formula`*
-Symlink all of *`formula`*'s installed files into the Homebrew prefix. This is
-done automatically when you install formulae but can be useful for DIY
-installations.
+Symlink all of *`formula`*'s installed files into Homebrew's prefix. This is done
+automatically when you install formulae but can be useful for DIY installations.
* `--overwrite`:
- Delete files already existing in the prefix while linking.
+ Delete files that already exist in the prefix while linking.
* `-n`, `--dry-run`:
- List all files which would be linked or deleted by `brew link --overwrite`, but will not actually link or delete any files.
+ List files which would be linked or deleted by `brew link --overwrite` without actually linking or deleting any files.
-### `list`, `ls` [*`options`*]
+### `list`, `ls` [*`options`*] [*`formula`*]
List all installed formulae.
+If *`formula`* is provided, summarize the paths within its current keg.
+
* `--full-name`:
- Print formulae with fully-qualified names. If `--full-name` is not passed, other options (i.e. `-1`, `-l`, `-t` and `-r`) are passed to `ls` which produces the actual output.
+ Print formulae with fully-qualified names. If `--full-name` is not passed, other options (i.e. `-1`, `-l`, `-r` and `-t`) are passed to `ls`(1) which produces the actual output.
* `--unbrewed`:
- List all files in the Homebrew prefix not installed by Homebrew.
+ List files in Homebrew's prefix not installed by Homebrew.
* `--versions`:
- Show the version number for installed formulae, or only the specified formulae if *`formula`* are given.
+ Show the version number for installed formulae, or only the specified formulae if *`formula`* are provided.
* `--multiple`:
Only show formulae with multiple versions installed.
* `--pinned`:
- Show the versions of pinned formulae, or only the specified (pinned) formulae if *`formula`* are given. See also `pin`, `unpin`.
+ Show the versions of pinned formulae, or only the specified (pinned) formulae if *`formula`* are provided. See also `pin`, `unpin`.
* `-1`:
Force output to be one entry per line. This is the default when output is not to a terminal.
* `-l`:
- List in long format. If the output is to a terminal, a total sum for all the file sizes is output on a line before the long listing.
+ List in long format. If the output is to a terminal, a total sum for all the file sizes is printed before the long listing.
* `-r`:
- Reverse the order of the sort to get the oldest entries first.
+ Reverse the order of the sort to list the oldest entries first.
* `-t`:
- Sort by time modified (most recently modified first).
+ Sort by time modified, listing most recently modified first.
-### `log` [*`options`*] *`formula`*
+### `log` [*`options`*] [*`formula`*]
-Show the `git log` for the given *`formula`*.
+Show the `git log` for *`formula`*, or show the log for the Homebrew repository if
+no formula is provided.
* `-p`, `--patch`:
- Also output patch from commit.
+ Also print patch from commit.
* `--stat`:
- Also output diffstat from commit.
+ Also print diffstat from commit.
* `--oneline`:
- Output only one line per commit.
+ Print only one line per commit.
* `-1`, `--max-count`:
- Output only one commit.
+ Print only one or a specified number of commits.
### `migrate` [*`options`*] *`formula`*
-Migrate renamed packages to new name, where *`formula`* are old names of packages.
-
-### `missing` [*`options`*] [*`formulae`*]
+Migrate renamed packages to new names, where *`formula`* are old names of
+packages.
-Check the given *`formula`* for missing dependencies. If no *`formula`* are given,
-check all installed brews.
+### `missing` [*`options`*] [*`formula`*]
-`missing` exits with a non-zero status if any formulae are missing dependencies.
+Check the given *`formula`* kegs for missing dependencies. If no *`formula`* are
+provided, check all kegs. Will exit with a non-zero status if any kegs are found
+to be missing dependencies.
* `--hide`:
- Act as if none of the provided *`hidden`* are installed. *`hidden`* should be comma-separated list of formulae.
+ Act as if none of the specified *`hidden`* are installed. *`hidden`* should be a comma-separated list of formulae.
-### `options` [*`options`*] *`formula`*
+### `options` [*`options`*] [*`formula`*]
-Display install options specific to *`formula`*
+Show install options specific to *`formula`*.
* `--compact`:
Show all options on a single line separated by spaces.
-* `--all`:
- Show options for all formulae.
* `--installed`:
- Show options for all installed formulae.
+ Show options for formulae that are currently installed.
+* `--all`:
+ Show options for all available formulae.
### `outdated` [*`options`*]
-Show formulae that have an updated version available.
-
-By default, version information is displayed in interactive shells, and
-suppressed otherwise.
+List installed formulae that have an updated version available. By default,
+version information is displayed in interactive shells, and suppressed
+otherwise.
* `--json`:
Print output in JSON format. Currently the default and only accepted value for *`version`* is `v1`. See the docs for examples of using the JSON output: <https://docs.brew.sh/Querying-Brew>
* `--fetch-HEAD`:
- Fetch the upstream repository to detect if the HEAD installation of the formula is outdated. Otherwise, the repository's HEAD will be checked for updates when a new stable or development version has been released.
+ Fetch the upstream repository to detect if the HEAD installation of the formula is outdated. Otherwise, the repository's HEAD will only be checked for updates when a new stable or development version has been released.
### `pin` *`formula`*
@@ -358,10 +358,10 @@ Rerun the post-install steps for *`formula`*.
### `readall` [*`options`*] [*`tap`*]
-Import all formulae from specified *`tap`* (defaults to all installed taps). This
-can be useful for debugging issues across all formulae when making significant
-changes to `formula.rb`, testing the performance of loading all formulae or to
-determine if any current formulae have Ruby issues.
+Import all formulae from the specified *`tap`*, or from all installed taps if none
+is provided. This can be useful for debugging issues across all formulae when
+making significant changes to `formula.rb`, testing the performance of loading
+all formulae or to determine if any current formulae have Ruby issues.
* `--aliases`:
Verify any alias symlinks in each tap.
@@ -370,35 +370,34 @@ determine if any current formulae have Ruby issues.
### `reinstall` [*`options`*] *`formula`*
-Uninstall and then install *`formula`* (with existing and any appended install
-options).
+Uninstall and then install *`formula`* using the same options it was originally
+installed with, plus any appended brew formula options.
-Unless `HOMEBREW_NO_INSTALL_CLEANUP` is set, `brew cleanup` will be run for the
-reinstalled formulae or, every 30 days, for all formulae.
+Unless `HOMEBREW_NO_INSTALL_CLEANUP` is set, `brew cleanup` will then be run for
+the reinstalled formulae or, every 30 days, for all formulae.
* `-s`, `--build-from-source`:
Compile *`formula`* from source even if a bottle is available.
* `--force-bottle`:
Install from a bottle if it exists for the current or newest version of macOS, even if it would not normally be used for installation.
* `--keep-tmp`:
- Don't delete the temporary files created during installation.
+ Retain the temporary files created during installation.
* `--display-times`:
Print install times for each formula at the end of the run.
### `search` [*`options`*] [*`text`*|`/`*`text`*`/`]
Perform a substring search of cask tokens and formula names for *`text`*. If
-*`text`* is surrounded with slashes, then it is interpreted as a regular
-expression. The search for *`text`* is extended online to `homebrew/core` and
-`homebrew/cask`.
+*`text`* is flanked by slashes, it is interpreted as a regular expression. The
+search for *`text`* is extended online to `homebrew/core` and `homebrew/cask`.
-If no *`text`* is passed, display all locally available formulae (including tapped
+If no *`text`* is provided, list all locally available formulae (including tapped
ones). No online search is performed.
* `--casks`:
- Display all locally available casks (including tapped ones). No online search is performed.
+ List all locally available casks (including tapped ones). No online search is performed.
* `--desc`:
- search formulae with a description matching *`text`* and casks with a name matching *`text`*.
+ Search for formulae with a description matching *`text`* and casks with a name matching *`text`*.
* `--macports`:
Search for *`text`* in the given package manager's list.
* `--fink`:
@@ -418,17 +417,17 @@ Start a Homebrew build environment shell. Uses our years-battle-hardened
Homebrew build logic to help your `./configure && make && make install` or even
your `gem install` succeed. Especially handy if you run Homebrew in an
Xcode-only configuration since it adds tools like `make` to your `PATH` which
-otherwise build systems would not find.
+build systems would not find otherwise.
* `--env`:
- Use the standard `PATH` instead of superenv's, when *`std`* is passed
+ Use the standard `PATH` instead of superenv's when `std` is passed.
### `shellenv`
-Prints export statements - run them in a shell and this installation of Homebrew will be included into your `PATH`, `MANPATH` and `INFOPATH`.
+Print export statements. When run in a shell, this installation of Homebrew will be added to your `PATH`, `MANPATH`, and `INFOPATH`.
-`HOMEBREW_PREFIX`, `HOMEBREW_CELLAR` and `HOMEBREW_REPOSITORY` are also exported to save multiple queries of those variables.
+The variables `HOMEBREW_PREFIX`, `HOMEBREW_CELLAR` and `HOMEBREW_REPOSITORY` are also exported to avoid querying them multiple times.
-Consider adding evaluating the output in your dotfiles (e.g. `~/.profile`) with `eval $(brew shellenv)`
+Consider adding evaluation of this command's output to your dotfiles (e.g. `~/.profile`) with: `eval $(brew shellenv)`
### `style` [*`options`*] [*`file`*|*`tap`*|*`formula`*]
@@ -449,26 +448,27 @@ and all formulae.
### `switch` *`formula`* *`version`*
-Symlink all of the specific *`version`* of *`formula`*'s install to Homebrew prefix.
+Symlink all of the specified *`version`* of *`formula`*'s installation into
+Homebrew's prefix.
### `tap` [*`options`*] *`user`*`/`*`repo`* [*`URL`*]
Tap a formula repository.
-List all installed taps when no arguments are passed.
+If no arguments are provided, list all installed taps.
-With *`URL`* unspecified, taps a formula repository from GitHub using HTTPS. Since
+With *`URL`* unspecified, tap a formula repository from GitHub using HTTPS. Since
so many taps are hosted on GitHub, this command is a shortcut for `brew 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.
+With *`URL`* specified, tap a formula repository from anywhere, using any
+transport protocol that `git`(1) 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.
* `--full`:
- Use a full clone when tapping a repository. By default, the repository is cloned as a shallow copy (`--depth=1`). To convert a shallow copy to a full copy, you can retap passing `--full` without first untapping.
+ Use a full clone when tapping a repository. By default, the repository is cloned as a shallow copy (`--depth=1`). To convert a shallow copy to a full copy, you can retap by passing `--full` without first untapping.
* `--force-auto-update`:
Auto-update tap even if it is not hosted on GitHub. By default, only taps hosted on GitHub are auto-updated (for performance reasons).
* `--repair`:
@@ -480,13 +480,14 @@ SSH, GIT, HTTP, FTP(S), RSYNC.
### `tap-info` [*`options`*] [*`tap`*]
-Display detailed information about one or more provided *`tap`*. Display a brief
-summary of all installed taps if no *`tap`* are passed.
+Show detailed information about one or more *`tap`*s.
+
+If no *`tap`* names are provided, display brief statistics for all installed taps.
* `--installed`:
- Display information on all installed taps.
+ Show information on each installed tap.
* `--json`:
- Print a JSON representation of *`taps`*. Currently the default and only accepted value for *`version`* is `v1`. See the docs for examples of using the JSON output: <https://docs.brew.sh/Querying-Brew>
+ Print a JSON representation of *`tap`*. Currently the default and only accepted value for *`version`* is `v1`. See the docs for examples of using the JSON output: <https://docs.brew.sh/Querying-Brew>
### `uninstall`, `rm`, `remove` [*`options`*] *`formula`*
@@ -497,12 +498,12 @@ Uninstall *`formula`*.
### `unlink` [*`options`*] *`formula`*
-Remove symlinks for *`formula`* from the Homebrew prefix. This can be useful for
+Remove symlinks for *`formula`* from Homebrew's prefix. This can be useful for
temporarily disabling a formula: `brew unlink` *`formula`* `&&` *`commands`* `&&
brew link` *`formula`*
* `-n`, `--dry-run`:
- List all files which would be unlinked, but will not actually unlink or delete any files.
+ List files which would be unlinked without actually unlinking or deleting any files.
### `unpack` [*`options`*] *`formula`*
@@ -523,57 +524,55 @@ also `pin`.
### `untap` *`tap`*
-Remove a tapped repository.
+Remove a tapped formula repository.
-### `update` [*`options`*]
+### `update`, `up` [*`options`*]
Fetch the newest version of Homebrew and all formulae from GitHub using `git`(1) and perform any necessary migrations.
* `--merge`:
- `git merge` is used to include updates (rather than `git rebase`).
+ Use `git merge` to apply updates (rather than `git rebase`).
### `update-reset` [*`repository`*]
-Fetches and resets Homebrew and all tap repositories (or any specified `repository`) using `git`(1) to their latest `origin/master`. Note this will destroy all your uncommitted or committed changes.
+Fetch and reset Homebrew and all tap repositories (or any specified *`repository`*) using `git`(1) to their latest `origin/master`.
-### `upgrade` [*`options`*] *`formula`*
+*Note:* this will destroy all your uncommitted or committed changes.
-Upgrade outdated, unpinned formulae (with existing and any appended brew formula
-options).
+### `upgrade` [*`options`*] [*`formula`*]
-If *`formula`* are given, upgrade only the specified brews (unless they are
-pinned; see `pin`, `unpin`).
+Upgrade outdated, unpinned formulae using the same options they were originally
+installed with, plus any appended brew formula options. If *`formula`* are
+specified, upgrade only the given *`formula`* kegs (unless they are pinned; see
+`pin`, `unpin`).
-Unless `HOMEBREW_NO_INSTALL_CLEANUP` is set, `brew cleanup` will be run for the
-upgraded formulae or, every 30 days, for all formulae.
+Unless `HOMEBREW_NO_INSTALL_CLEANUP` is set, `brew cleanup` will then be run for
+the upgraded formulae or, every 30 days, for all formulae.
* `-s`, `--build-from-source`:
Compile *`formula`* from source even if a bottle is available.
* `--force-bottle`:
Install from a bottle if it exists for the current or newest version of macOS, even if it would not normally be used for installation.
* `--fetch-HEAD`:
- Fetch the upstream repository to detect if the HEAD installation of the formula is outdated. Otherwise, the repository's HEAD will be checked for updates when a new stable or development version has been released.
+ Fetch the upstream repository to detect if the HEAD installation of the formula is outdated. Otherwise, the repository's HEAD will only be checked for updates when a new stable or development version has been released.
* `--ignore-pinned`:
- Set a 0 exit code even if pinned formulae are not upgraded.
+ Set a successful exit status even if pinned formulae are not upgraded.
* `--keep-tmp`:
- Don't delete the temporary files created during installation.
+ Retain the temporary files created during installation.
* `--display-times`:
Print install times for each formula at the end of the run.
* `--dry-run`:
Show what would be upgraded, but do not actually upgrade anything.
### `uses` [*`options`*] *`formula`*
-Show the formulae that specify *`formula`* as a dependency. When given multiple
-formula arguments, show the intersection of formulae that use *`formula`*.
-
-By default, `uses` shows all formulae that specify *`formula`* as a required or
-recommended dependency.
-
-By default, `uses` shows usage of *`formula`* by stable builds.
+Show formulae that specify *`formula`* as a dependency. When given multiple
+formula arguments, show the intersection of formulae that use *`formula`*. By
+default, `uses` shows all formulae that specify *`formula`* as a required or
+recommended dependency for their stable builds.
* `--recursive`:
Resolve more than one level of dependencies.
* `--installed`:
- Only list installed formulae.
+ Only list formulae that are currently installed.
* `--include-build`:
Include all formulae that specify *`formula`* as `:build` type dependency.
* `--include-test`:
@@ -583,9 +582,9 @@ By default, `uses` shows usage of *`formula`* by stable builds.
* `--skip-recommended`:
Skip all formulae that specify *`formula`* as `:recommended` type dependency.
* `--devel`:
- Show usage of *`formula`* by development build.
+ Show usage of *`formula`* by development builds.
* `--HEAD`:
- Show usage of *`formula`* by HEAD build.
+ Show usage of *`formula`* by HEAD builds.
### `--cache` [*`options`*] [*`formula`*]
@@ -608,15 +607,15 @@ would be installed, without any sort of versioned directory as the last path.
### `--env` [*`options`*]
-Show a summary of the Homebrew build environment as a plain list.
+Summarize Homebrew's build environment as a plain list.
If the command's output is sent through a pipe and no shell is specified, the
list is formatted for export to `bash`(1) unless `--plain` is passed.
* `--shell`:
Generate a list of environment variables for the specified shell, or `--shell=auto` to detect the current shell.
* `--plain`:
- Plain output even when piped.
+ Generate plain output even when piped.
### `--prefix` [*`formula`*]
@@ -626,7 +625,7 @@ Display Homebrew's install path. *Default:* `/usr/local` on macOS and
If *`formula`* is provided, display the location in the cellar where *`formula`* is
or would be installed.
-### `--repository` [*`user`*`/`*`repo`*]
+### `--repository`, `--repo` [*`user`*`/`*`repo`*]
Display where Homebrew's `.git` directory is located.
@@ -635,17 +634,17 @@ is located.
### `--version`
-Print the version number of Homebrew, Homebrew/homebrew-core and
-Homebrew/homebrew-cask (if tapped) to standard output and exit.
+Print the version numbers of Homebrew, Homebrew/homebrew-core and
+Homebrew/homebrew-cask (if tapped) to standard output.
## DEVELOPER COMMANDS
-### `audit` [*`options`*] *`formula`*
+### `audit` [*`options`*] [*`formula`*]
Check *`formula`* for Homebrew coding style violations. This should be run before
-submitting a new formula. Will exit with a non-zero status if any errors are
-found, which can be useful for implementing pre-commit hooks. If no *`formula`*
-are provided, all of them are checked.
+submitting a new formula. If no *`formula`* are provided, check all locally
+available formulae. Will exit with a non-zero status if any errors are found,
+which can be useful for implementing pre-commit hooks.
* `--strict`:
Run additional style checks, including RuboCop style checks.
@@ -658,7 +657,7 @@ are provided, all of them are checked.
* `--display-cop-names`:
Include the RuboCop cop name for each violation in the output.
* `--display-filename`:
- Prefix every line of output with name of the file or formula being audited, to make output easy to grep.
+ Prefix every line of output with the file or formula name being audited, to make output easy to grep.
* `-D`, `--audit-debug`:
Enable debugging and profiling of audit methods.
* `--only`:
@@ -688,19 +687,19 @@ at its original value, while `--no-rebuild` will remove it.
* `--keep-old`:
If the formula specifies a rebuild version, attempt to preserve its value in the generated DSL.
* `--json`:
- Write bottle information to a JSON file, which can be used as the argument for `--merge`.
+ Write bottle information to a JSON file, which can be used as the value for `--merge`.
* `--merge`:
- Generate an updated bottle block for a formula and optionally merge it into the formula file. Instead of a formula name, requires a JSON file generated with `brew bottle --json` *`formula`*.
+ Generate an updated bottle block for a formula and optionally merge it into the formula file. Instead of a formula name, requires the path to a JSON file generated with `brew bottle --json` *`formula`*.
* `--write`:
- Write the changes to the formula file. A new commit will be generated unless `--no-commit` is passed.
+ Write changes to the formula file. A new commit will be generated unless `--no-commit` is passed.
* `--no-commit`:
When passed with `--write`, a new commit will not generated after writing changes to the formula file.
* `--root-url`:
Use the specified *`URL`* as the root of the bottle's URL instead of Homebrew's default.
### `bump-formula-pr` [*`options`*] [*`formula`*]
-Create a pull request to update a formula with a new URL or a new tag.
+Create a pull request to update *`formula`* with a new URL or a new tag.
If a *`URL`* is specified, the *`SHA-256`* checksum of the new download should also
be specified. A best effort to determine the *`SHA-256`* and *`formula`* name will
@@ -711,8 +710,8 @@ must also be specified.
*Note:* this command cannot be used to transition a formula from a
URL-and-SHA-256 style specification into a tag-and-revision style specification,
-nor vice versa. It must use whichever style specification the preexisting
-formula already uses.
+nor vice versa. It must use whichever style specification the formula already
+uses.
* `--devel`:
Bump the development rather than stable version. The development spec must already exist.
@@ -727,29 +726,29 @@ formula already uses.
* `--no-browse`:
Print the pull request URL instead of opening in a browser.
* `--mirror`:
- Use the provided *`URL`* as a mirror URL.
+ Use the specified *`URL`* as a mirror URL.
* `--version`:
- Use the provided *`version`* to override the value parsed from the URL or tag. Note that `--version=0` can be used to delete an existing version override from a formula if it has become redundant.
+ Use the specified *`version`* to override the value parsed from the URL or tag. Note that `--version=0` can be used to delete an existing version override from a formula if it has become redundant.
* `--message`:
- Append the provided *`message`* to the default PR message.
+ Append *`message`* to the default pull request message.
* `--url`:
Specify the *`URL`* for the new download. If a *`URL`* is specified, the *`SHA-256`* checksum of the new download should also be specified.
* `--sha256`:
Specify the *`SHA-256`* checksum of the new download.
* `--tag`:
Specify the new git commit *`tag`* for the formula.
* `--revision`:
- Specify the new git commit *`revision`* corresponding to a specified *`tag`*.
+ Specify the new git commit *`revision`* corresponding to the specified *`tag`*.
-### `bump-revision` [*`options`*] [*`formula`*]
+### `bump-revision` [*`options`*] *`formula`*
-Create a commit to increment the revision of the formula. If no revision is
- present, "revision 1" will be added.
+Create a commit to increment the revision of *`formula`*. If no revision is
+present, "revision 1" will be added.
* `-n`, `--dry-run`:
Print what would be done rather than doing it.
* `--message`:
- Append the provided *`message`* to the default commit message.
+ Append *`message`* to the default commit message.
### `create` [*`options`*] *`URL`*
@@ -766,34 +765,35 @@ a simple example. For the complete API, see:
* `--meson`:
Create a basic template for a Meson-style build.
* `--no-fetch`:
- Homebrew will not download *`URL`* to the cache and will thus not add the SHA-256 to the formula for you, nor will it check the GitHub API for GitHub projects (to fill out its description and homepage).
+ Homebrew will not download *`URL`* to the cache and will thus not add its SHA-256 to the formula for you, nor will it check the GitHub API for GitHub projects (to fill out its description and homepage).
* `--HEAD`:
Indicate that *`URL`* points to the package's repository rather than a file.
* `--set-name`:
- Set the name of the new formula to the provided *`name`*.
+ Explicitly set the *`name`* of the new formula.
* `--set-version`:
- Set the version of the new formula to the provided *`version`*.
+ Explicitly set the *`version`* of the new formula.
* `--tap`:
- Generate the new formula in the provided tap, specified as *`user`*`/`*`repo`*.
+ Generate the new formula within the given tap, specified as *`user`*`/`*`repo`*.
### `edit` [*`formula`*]
-Open a formula in the editor set by `EDITOR` or `HOMEBREW_EDITOR`, or open the
-Homebrew repository for editing if no *`formula`* is provided.
+Open *`formula`* in the editor set by `EDITOR` or `HOMEBREW_EDITOR`, or open the
+Homebrew repository for editing if no formula is provided.
### `extract` [*`options`*] *`formula`* *`tap`*
Look through repository history to find the most recent version of *`formula`* and
create a copy in *`tap`*`/Formula/`*`formula`*`@`*`version`*`.rb`. If the tap is not
installed yet, attempt to install/clone the tap before continuing. To extract a
-*`formula`* from a tap that is not homebrew/core use *`user`*/*`repo`*/*`formula`*.
+formula from a tap that is not `homebrew/core` use its fully-qualified form of
+*`user`*`/`*`repo`*`/`*`formula`*.
* `--version`:
- Extract the provided *`version`* of *`formula`* instead of the most recent.
+ Extract the specified *`version`* of *`formula`* instead of the most recent.
### `formula` *`formula`*
-Display the path where a formula is located.
+Display the path where *`formula`* is located.
### `irb` [*`options`*]
@@ -806,11 +806,11 @@ Enter the interactive Homebrew Ruby shell.
### `linkage` [*`options`*] [*`formula`*]
-Check the library links for kegs of installed formulae. Raises an error if run
-on uninstalled formulae.
+Check the library links from the given *`formula`* kegs. If no *`formula`* are
+provided, check all kegs. Raises an error if run on uninstalled formulae.
* `--test`:
- Display only missing libraries and exit with a non-zero status if any missing libraries are found.
+ Show only missing libraries and exit with a non-zero status if any missing libraries are found.
* `--reverse`:
For every library that a keg references, print its dylib path followed by the binaries that link to it.
* `--cached`:
@@ -821,21 +821,21 @@ on uninstalled formulae.
Generate Homebrew's manpages.
* `--fail-if-changed`:
- Return a failing status code if changes are detected in the manpage outputs. This can be used for CI to be notified when the manpages are out of date. Additionally, the date used in new manpages will match those in the existing manpages (to allow comparison without factoring in the date).
+ Return a failing status code if changes are detected in the manpage outputs. This can be used to notify CI when the manpages are out of date. Additionally, the date used in new manpages will match those in the existing manpages (to allow comparison without factoring in the date).
* `--link`:
This is now done automatically by `brew update`.
### `prof` *`command`*
-Run Homebrew with the Ruby profiler e.g. `brew prof readall`.
+Run Homebrew with the Ruby profiler, e.g. `brew prof readall`.
### `pull` [*`options`*] *`patch`*
Get a patch from a GitHub commit or pull request and apply it to Homebrew.
-Optionally, publish updated bottles for the formulae changed by the patch.
+Optionally, publish updated bottles for any formulae changed by the patch.
-Each *`patch`* may be the number of a PR in `homebrew/core`, the URL of a PR on
-GitHub, the URL of a commit on GitHub or a "https://jenkins.brew.sh/job/..."
+Each *`patch`* may be the number of a pull request in `homebrew/core`, the URL of
+any pull request or commit on GitHub or a "https://jenkins.brew.sh/job/..."
testing job URL.
* `--bottle`:
@@ -857,9 +857,9 @@ testing job URL.
* `--warn-on-publish-failure`:
Do not exit if there's a failure publishing bottles on Bintray.
* `--bintray-org`:
- Publish bottles at the provided Bintray *`organisation`*.
+ Publish bottles to the specified Bintray *`organisation`*.
* `--test-bot-user`:
- Pull the bottle block commit from the provided *`user`* on GitHub.
+ Pull the bottle block commit from the specified *`user`* on GitHub.
### `release-notes` [*`options`*] [*`previous_tag`*] [*`end_ref`*]
@@ -870,13 +870,13 @@ provided it defaults to `origin/master`.
* `--markdown`:
Print as a Markdown list.
-### `ruby` [`-e`]:
+### `ruby` (`-e` *`text`*|*`file`*)
-Run a Ruby instance with Homebrew's libraries loaded e.g. `brew ruby -e "puts
-:gcc.f.deps"` or `brew ruby script.rb`
+Run a Ruby instance with Homebrew's libraries loaded, e.g. `brew ruby -e "puts
+:gcc.f.deps"` or `brew ruby script.rb`.
* `-e`:
- Execute the provided string argument as a script.
+ Execute the given text string as a script.
### `tap-new` *`user`*`/`*`repo`*
@@ -895,7 +895,7 @@ wrong with the installed formula.
* `--HEAD`:
Test the head version of a formula.
* `--keep-tmp`:
- Keep the temporary files created for the test.
+ Retain the temporary files created for the test.
### `tests` [*`options`*]
@@ -912,21 +912,21 @@ Run Homebrew's unit and integration tests.
* `--only`:
Run only *`test_script`*`_spec.rb`. Appending `:`*`line_number`* will start at a specific line.
* `--seed`:
- Randomise tests with the provided *`value`* instead of a random seed.
+ Randomise tests with the specified *`value`* instead of a random seed.
### `update-test` [*`options`*]
-Run a test of `brew update` with a new repository clone. If no arguments are
+Run a test of `brew update` with a new repository clone. If no options are
passed, use `origin/master` as the start commit.
* `--to-tag`:
Set `HOMEBREW_UPDATE_TO_TAG` to test updating between tags.
* `--keep-tmp`:
Retain the temporary directory containing the new repository clone.
* `--commit`:
- Use provided *`commit`* as the start commit.
+ Use the specified *`commit`* as the start commit.
* `--before`:
- Use the commit at provided *`date`* as the start commit.
+ Use the commit at the specified *`date`* as the start commit.
### `vendor-gems`
@@ -952,19 +952,21 @@ These options are applicable across all sub-commands.
### `bundle` *`subcommand`*:
-Bundler for non-Ruby dependencies from Homebrew, Homebrew Cask and the Mac App Store. See `brew bundle --help`.
+Bundler for non-Ruby dependencies from Homebrew, Homebrew Cask and the Mac App Store.
+See `brew bundle --help`.
**Homebrew/homebrew-bundle**: <https://github.com/Homebrew/homebrew-bundle>
### `cask` *`subcommand`*:
-Install macOS applications distributed as binaries. See brew-cask(1).
+Install macOS applications distributed as binaries. See `brew-cask`(1).
**Homebrew/homebrew-cask**: <https://github.com/Homebrew/homebrew-cask>
### `services` *`subcommand`*:
-Manage background services with macOS' `launchctl`(1) daemon manager. See `brew services --help`.
+Manage background services with macOS' `launchctl`(1) daemon manager.
+See `brew services --help`.
**Homebrew/homebrew-services**: <https://github.com/Homebrew/homebrew-services>
@@ -995,17 +997,18 @@ can take several different forms:
* An arbitrary file or URL:
Homebrew can install formulae via URL, e.g.
`https://raw.githubusercontent.com/Homebrew/homebrew-core/master/Formula/git.rb`,
- or from a local path. It could point to either a formula file or a bottle.
+ or from a local path. It can point to either a formula file or a bottle.
In the case of a URL, the downloaded file will be cached for later use.
## ENVIRONMENT
-Note that environment variables must have a value set to be detected. For example,
+Note that environment variables must have a value set to be detected. For example, run
`export HOMEBREW_NO_INSECURE_REDIRECT=1` rather than just
`export HOMEBREW_NO_INSECURE_REDIRECT`.
* `HOMEBREW_ARCH`:
- Linux only: If set, Homebrew will pass the set value to type name to the compiler's `-march` option instead of using the default (`-march=native`).
+ Linux only: If set, Homebrew will pass the set value to type name to the compiler's
+ `-march` option instead of using the default (`-march=native`).
* `HOMEBREW_ARTIFACT_DOMAIN`:
If set, instructs Homebrew to prefix all download URLs, including those for bottles,
@@ -1041,8 +1044,8 @@ Note that environment variables must have a value set to be detected. For exampl
*Default:* `~/Library/Caches/Homebrew`.
* `HOMEBREW_CURLRC`:
- If set, Homebrew will not pass `-q` when invoking `curl`(1) (which disables
- the use of `curlrc`).
+ If set, Homebrew will not pass `-q` when invoking `curl`(1), which disables
+ the use of `curlrc`.
* `HOMEBREW_CURL_VERBOSE`:
If set, Homebrew will pass `--verbose` when invoking `curl`(1).
@@ -1083,7 +1086,7 @@ Note that environment variables must have a value set to be detected. For exampl
even if the system version of Ruby is new enough.
* `HOMEBREW_FORCE_BREWED_GIT`:
- If set, Homebrew will always use a Homebrew-installed `git` rather than the
+ If set, Homebrew will always use a Homebrew-installed `git`(1) rather than the
system version. Automatically set if the system version of `git` is too old.
* `HOMEBREW_GITHUB_API_TOKEN`:
@@ -1208,6 +1211,8 @@ And for an authenticated HTTP proxy:
Homebrew Documentation: <https://docs.brew.sh>
+Homebrew API: <https://rubydoc.brew.sh>
+
`brew-cask`(1), `git`(1), `git-log`(1)
## AUTHORS | true |
Other | Homebrew | brew | 20e3edfc780f6ca096e5d762a73abbf3182f0eda.json | manpages: add link to API & regenerate | manpages/brew.1 | @@ -19,36 +19,39 @@ Homebrew is the easiest and most flexible way to install the UNIX tools Apple di
For the full command list, see the \fICOMMANDS\fR section\.
.
.P
-With \fB\-\-verbose\fR or \fB\-v\fR, many commands print extra debugging information\. Note that these flags should only appear after a command\.
+With \fB\-\-verbose\fR or \fB\-\-debug\fR, many commands print extra debugging information\. Note that these options should only appear after a command\.
.
.SS "\fBinstall\fR \fIformula\fR:"
Install \fIformula\fR\.
.
+.P
+\fIformula\fR is usually the name of the formula to install, but it has other syntaxes which are listed in the \fISPECIFYING FORMULAE\fR section\.
+.
.SS "\fBuninstall\fR \fIformula\fR:"
Uninstall \fIformula\fR\.
.
.SS "\fBlist\fR:"
List all installed formulae\.
.
.SS "\fBsearch\fR (\fItext\fR|\fB/\fR\fItext\fR\fB/\fR):"
-Perform a substring search of cask tokens and formula names for \fItext\fR\. If \fItext\fR is surrounded with slashes, then it is interpreted as a regular expression\. The search for \fItext\fR is extended online to \fBhomebrew/core\fR and \fBhomebrew/cask\fR\. If no search term is given, all locally available formulae are listed\.
+Perform a substring search of cask tokens and formula names for \fItext\fR\. If \fItext\fR is flanked by slashes, it is interpreted as a regular expression\. The search for \fItext\fR is extended online to \fBhomebrew/core\fR and \fBhomebrew/cask\fR\. If no search term is provided, all locally available formulae are listed\.
.
.SH "COMMANDS"
.
-.SS "\fBanalytics\fR [\fBon\fR|\fBoff\fR|\fBstate\fR|\fBregenerate\-uuid\fR]"
+.SS "\fBanalytics\fR [\fIsubcommand\fR]"
If \fBon\fR or \fBoff\fR is passed, turn Homebrew\'s analytics on or off respectively\.
.
.P
-If \fBstate\fR is passed, display anonymous user behaviour analytics state\. Read more at \fIhttps://docs\.brew\.sh/Analytics\fR\.
+If \fBstate\fR is passed, display the current anonymous user behaviour analytics state\. Read more at \fIhttps://docs\.brew\.sh/Analytics\fR\.
.
.P
-If \fBregenerate\-uuid\fR is passed, regenerate UUID used in Homebrew\'s analytics\.
+If \fBregenerate\-uuid\fR is passed, regenerate the UUID used in Homebrew\'s analytics\.
.
.SS "\fBcat\fR \fIformula\fR"
Display the source of \fIformula\fR\.
.
.SS "\fBcleanup\fR [\fIoptions\fR] [\fIformula\fR|\fIcask\fR]"
-Remove stale lock files and outdated downloads for formulae and casks, and remove old versions of installed formulae\. If arguments are specified, only do this for the specified formulae and casks\.
+Remove stale lock files and outdated downloads for all formulae and casks, and remove old versions of installed formulae\. If arguments are specified, only do this for the given formulae and casks\.
.
.TP
\fB\-\-prune\fR
@@ -67,24 +70,24 @@ Scrub the cache, including downloads for even the latest versions\. Note downloa
Only prune the symlinks and directories from the prefix and remove no other files\.
.
.SS "\fBcommand\fR \fIcmd\fR"
-Display the path to the file which is used when invoking \fBbrew\fR \fIcmd\fR\.
+Display the path to the file being used when invoking \fBbrew\fR \fIcmd\fR\.
.
.SS "\fBcommands\fR [\fIoptions\fR]"
-Show a list of built\-in and external commands\.
+Show lists of built\-in and external commands\.
.
.TP
\fB\-\-include\-aliases\fR
-Include the aliases of internal commands\.
+Include aliases of internal commands\.
.
.SS "\fBconfig\fR"
-Show Homebrew and system configuration useful for debugging\. If you file a bug report, you will likely be asked for this information if you do not provide it\.
+Show Homebrew and system configuration info useful for debugging\. If you file a bug report, you will be required to provide this information\.
.
-.SS "\fBdeps\fR [\fIoptions\fR] \fIformula\fR"
+.SS "\fBdeps\fR [\fIoptions\fR] [\fIformula\fR]"
Show dependencies for \fIformula\fR\. Additional options specific to \fIformula\fR may be appended to the command\. When given multiple formula arguments, show the intersection of dependencies for each formula\.
.
.TP
\fB\-n\fR
-Show dependencies in topological order\.
+Sort dependencies in topological order\.
.
.TP
\fB\-\-1\fR
@@ -136,36 +139,36 @@ List dependencies for all available formulae\.
.
.TP
\fB\-\-for\-each\fR
-Switch into the mode used by the \fB\-\-all\fR option, but only list dependencies for the specified \fIformula\fR, one formula per line\. This is used for debugging the \fB\-\-installed\fR/\fB\-\-all\fR display mode\.
+Switch into the mode used by the \fB\-\-all\fR option, but only list dependencies for each provided \fIformula\fR, one formula per line\. This is used for debugging the \fB\-\-installed\fR/\fB\-\-all\fR display mode\.
.
.SS "\fBdesc\fR [\fIoptions\fR] (\fItext\fR|\fB/\fR\fItext\fR\fB/\fR|\fIformula\fR)"
Display \fIformula\fR\'s name and one\-line description\. Formula descriptions are cached; the cache is created on the first search, making that search slower than subsequent ones\.
.
.TP
\fB\-s\fR, \fB\-\-search\fR
-Search both name and description for provided \fItext\fR\. If \fItext\fR is flanked by slashes, it is interpreted as a regular expression\.
+Search both names and descriptions for \fItext\fR\. If \fItext\fR is flanked by slashes, it is interpreted as a regular expression\.
.
.TP
\fB\-n\fR, \fB\-\-name\fR
-Search just the names for provided \fItext\fR\. If \fItext\fR is flanked by slashes, it is interpreted as a regular expression\.
+Search just names for \fItext\fR\. If \fItext\fR is flanked by slashes, it is interpreted as a regular expression\.
.
.TP
\fB\-d\fR, \fB\-\-description\fR
-Search just the descriptions for provided \fItext\fR\. If \fItext\fR is flanked by slashes, it is interpreted as a regular expression\.
+Search just descriptions for \fItext\fR\. If \fItext\fR is flanked by slashes, it is interpreted as a regular expression\.
.
.SS "\fBdiy\fR [\fIoptions\fR]"
Automatically determine the installation prefix for non\-Homebrew software\. Using the output from this command, you can install your own software into the Cellar and then link it into Homebrew\'s prefix with \fBbrew link\fR\.
.
.TP
\fB\-\-name\fR
-Explicitly set the provided \fIname\fR of the package being installed\.
+Explicitly set the \fIname\fR of the package being installed\.
.
.TP
\fB\-\-version\fR
-Explicitly set the provided \fIversion\fR of the package being installed\.
+Explicitly set the \fIversion\fR of the package being installed\.
.
.SS "\fBdoctor\fR [\fIoptions\fR]"
-Check your system for potential problems\. Doctor exits with a non\-zero status if any potential problems are found\. Please note that these warnings are just used to help the Homebrew maintainers with debugging if you file an issue\. If everything you use Homebrew for is working fine: please don\'t worry or file an issue; just ignore this\.
+Check your system for potential problems\. Will exit with a non\-zero status if any potential problems are found\. Please note that these warnings are just used to help the Homebrew maintainers with debugging if you file an issue\. If everything you use Homebrew for is working fine: please don\'t worry or file an issue; just ignore this\.
.
.TP
\fB\-\-list\-checks\fR
@@ -176,7 +179,7 @@ List all audit methods\.
Enable debugging and profiling of audit methods\.
.
.SS "\fBfetch\fR [\fIoptions\fR] \fIformula\fR"
-Download the source packages for the given \fIformula\fR\. For tarballs, also print SHA\-256 checksums\.
+Download a bottle (if available) or source packages for \fIformula\fR\. For tarballs, also print SHA\-256 checksums\.
.
.TP
\fB\-\-HEAD\fR
@@ -188,57 +191,51 @@ Fetch development version instead of stable version\.
.
.TP
\fB\-\-retry\fR
-Retry if a download fails or re\-download if the checksum of a previously cached version no longer matches\.
+Retry if downloading fails or re\-download if the checksum of a previously cached version no longer matches\.
.
.TP
\fB\-\-deps\fR
-Download dependencies for any listed \fIformula\fR\.
+Also download dependencies for any listed \fIformula\fR\.
.
.TP
\fB\-s\fR, \fB\-\-build\-from\-source\fR
-Download the source for rather than a bottle\.
+Download source packages rather than a bottle\.
.
.TP
\fB\-\-build\-bottle\fR
-Download the source (for eventual bottling) rather than a bottle\.
+Download source packages (for eventual bottling) rather than a bottle\.
.
.TP
\fB\-\-force\-bottle\fR
Download a bottle if it exists for the current or newest version of macOS, even if it would not be used during installation\.
.
.SS "\fBgist\-logs\fR [\fIoptions\fR] \fIformula\fR"
-Upload logs for a failed build of \fIformula\fR to a new Gist\.
-.
-.P
-\fIformula\fR is usually the name of the formula to install, but it can be specified in several different ways\.
-.
-.P
-If no logs are found, an error message is presented\.
+Upload logs for a failed build of \fIformula\fR to a new Gist\. Presents an error message if no logs are found\.
.
.TP
\fB\-\-with\-hostname\fR
Include the hostname in the Gist\.
.
.TP
\fB\-n\fR, \fB\-\-new\-issue\fR
-Automatically create a new issue in the appropriate GitHub repository as well as creating the Gist\.
+Automatically create a new issue in the appropriate GitHub repository after creating the Gist\.
.
.TP
\fB\-p\fR, \fB\-\-private\fR
-The Gist will be marked private and will not appear in listings but will be accessible with the link\.
+The Gist will be marked private and will not appear in listings but will be accessible with its link\.
.
.SS "\fBhome\fR [\fIformula\fR]"
-Open \fIformula\fR\'s homepage in a browser\. If no formula is provided, open Homebrew\'s own homepage in a browser\.
+Open \fIformula\fR\'s homepage in a browser, or open Homebrew\'s own homepage if no formula is provided\.
.
.SS "\fBinfo\fR [\fIoptions\fR] [\fIformula\fR]"
Display brief statistics for your Homebrew installation\.
.
.P
-If \fIformula\fR is specified, show summary of information about \fIformula\fR\.
+If \fIformula\fR is provided, show summary of information about \fIformula\fR\.
.
.TP
\fB\-\-analytics\fR
-Display global Homebrew analytics data or, if specified, installation and build error data for \fIformula\fR (provided neither \fBHOMEBREW_NO_ANALYTICS\fR nor \fBHOMEBREW_NO_GITHUB_API\fR are set)\.
+List global Homebrew analytics data or, if specified, installation and build error data for \fIformula\fR (provided neither \fBHOMEBREW_NO_ANALYTICS\fR nor \fBHOMEBREW_NO_GITHUB_API\fR are set)\.
.
.TP
\fB\-\-days\fR
@@ -250,7 +247,7 @@ Which type of global analytics data to retrieve\. The value for \fIcategory\fR m
.
.TP
\fB\-\-github\fR
-Open a browser to the GitHub source page for \fIformula\fR\. To view formula history locally: \fBbrew log \-p\fR \fIformula\fR
+Open the GitHub source page for \fIformula\fR in a browser\. To view formula history locally: \fBbrew log \-p\fR \fIformula\fR
.
.TP
\fB\-\-json\fR
@@ -265,41 +262,38 @@ Print JSON of formulae that are currently installed\.
Print JSON of all available formulae\.
.
.SS "\fBinstall\fR [\fIoptions\fR] \fIformula\fR"
-Install \fIformula\fR\.
+Install \fIformula\fR\. Additional options specific to \fIformula\fR may be appended to the command\.
.
.P
-\fIformula\fR is usually the name of the formula to install, but it can be specified in several different ways\.
-.
-.P
-Unless \fBHOMEBREW_NO_INSTALL_CLEANUP\fR is set, \fBbrew cleanup\fR will be run for the installed formulae or, every 30 days, for all formulae\.
+Unless \fBHOMEBREW_NO_INSTALL_CLEANUP\fR is set, \fBbrew cleanup\fR will then be run for the installed formulae or, every 30 days, for all formulae\.
.
.TP
\fB\-\-env\fR
-If \fBstd\fR is passed, use the standard build environment instead of superenv\.If \fBsuper\fR is passed, use superenv even if the formula specifies the standard build environment\.
+If \fBstd\fR is passed, use the standard build environment instead of superenv\. If \fBsuper\fR is passed, use superenv even if the formula specifies the standard build environment\.
.
.TP
\fB\-\-ignore\-dependencies\fR
An unsupported Homebrew development flag to skip installing any dependencies of any kind\. If the dependencies are not already present, the formula will have issues\. If you\'re not developing Homebrew, consider adjusting your PATH rather than using this flag\.
.
.TP
\fB\-\-only\-dependencies\fR
-Install the dependencies with specified options but do not install the specified formula\.
+Install the dependencies with specified options but do not install the formula itself\.
.
.TP
\fB\-\-cc\fR
-Attempt to compile using provided \fIcompiler\fR\. \fIcompiler\fR should be the name of the compiler\'s executable, for instance \fBgcc\-7\fR for GCC 7\. In order to use LLVM\'s clang, use \fBllvm_clang\fR\. To specify the Apple\-provided clang, use \fBclang\fR\. This parameter will only accept compilers that are provided by Homebrew or bundled with macOS\. Please do not file issues if you encounter errors while using this flag\.
+Attempt to compile using the specified \fIcompiler\fR, which should be the name of the compiler\'s executable, e\.g\. \fBgcc\-7\fR for GCC 7\. In order to use LLVM\'s clang, specify \fBllvm_clang\fR\. To use the Apple\-provided clang, specify \fBclang\fR\. This option will only accept compilers that are provided by Homebrew or bundled with macOS\. Please do not file issues if you encounter errors while using this option\.
.
.TP
\fB\-s\fR, \fB\-\-build\-from\-source\fR
-Compile the specified \fIformula\fR from source even if a bottle is provided\. Dependencies will still be installed from bottles if they are available\.
+Compile \fIformula\fR from source even if a bottle is provided\. Dependencies will still be installed from bottles if they are available\.
.
.TP
\fB\-\-force\-bottle\fR
Install from a bottle if it exists for the current or newest version of macOS, even if it would not normally be used for installation\.
.
.TP
\fB\-\-include\-test\fR
-Install testing dependencies required to run \fBbrew test\fR\.
+Install testing dependencies required to run \fBbrew test\fR \fIformula\fR\.
.
.TP
\fB\-\-devel\fR
@@ -311,19 +305,19 @@ If \fIformula\fR defines it, install the HEAD version, aka\. master, trunk, unst
.
.TP
\fB\-\-fetch\-HEAD\fR
-Fetch the upstream repository to detect if the HEAD installation of the formula is outdated\. Otherwise, the repository\'s HEAD will be checked for updates when a new stable or development version has been released\.
+Fetch the upstream repository to detect if the HEAD installation of the formula is outdated\. Otherwise, the repository\'s HEAD will only be checked for updates when a new stable or development version has been released\.
.
.TP
\fB\-\-keep\-tmp\fR
-Don\'t delete the temporary files created during installation\.
+Retain the temporary files created during installation\.
.
.TP
\fB\-\-build\-bottle\fR
-Prepare the formula for eventual bottling during installation\.
+Prepare the formula for eventual bottling during installation, skipping any post\-install steps\.
.
.TP
\fB\-\-bottle\-arch\fR
-Optimise bottles for the given architecture rather than the oldest architecture supported by the version of macOS the bottles are built on\.
+Optimise bottles for the specified architecture rather than the oldest architecture supported by the version of macOS the bottles are built on\.
.
.TP
\fB\-\-display\-times\fR
@@ -338,118 +332,115 @@ Download and patch \fIformula\fR, then open a shell\. This allows the user to ru
Create a Git repository, useful for creating patches to the software\.
.
.SS "\fBleaves\fR"
-Show installed formulae that are not dependencies of another installed formula\.
+List installed formulae that are not dependencies of another installed formula\.
.
-.SS "\fBln\fR, \fBlink\fR [\fIoptions\fR] \fIformula\fR"
-Symlink all of \fIformula\fR\'s installed files into the Homebrew prefix\. This is done automatically when you install formulae but can be useful for DIY installations\.
+.SS "\fBlink\fR, \fBln\fR [\fIoptions\fR] \fIformula\fR"
+Symlink all of \fIformula\fR\'s installed files into Homebrew\'s prefix\. This is done automatically when you install formulae but can be useful for DIY installations\.
.
.TP
\fB\-\-overwrite\fR
-Delete files already existing in the prefix while linking\.
+Delete files that already exist in the prefix while linking\.
.
.TP
\fB\-n\fR, \fB\-\-dry\-run\fR
-List all files which would be linked or deleted by \fBbrew link \-\-overwrite\fR, but will not actually link or delete any files\.
+List files which would be linked or deleted by \fBbrew link \-\-overwrite\fR without actually linking or deleting any files\.
.
-.SS "\fBlist\fR, \fBls\fR [\fIoptions\fR]"
+.SS "\fBlist\fR, \fBls\fR [\fIoptions\fR] [\fIformula\fR]"
List all installed formulae\.
.
+.P
+If \fIformula\fR is provided, summarize the paths within its current keg\.
+.
.TP
\fB\-\-full\-name\fR
-Print formulae with fully\-qualified names\. If \fB\-\-full\-name\fR is not passed, other options (i\.e\. \fB\-1\fR, \fB\-l\fR, \fB\-t\fR and \fB\-r\fR) are passed to \fBls\fR which produces the actual output\.
+Print formulae with fully\-qualified names\. If \fB\-\-full\-name\fR is not passed, other options (i\.e\. \fB\-1\fR, \fB\-l\fR, \fB\-r\fR and \fB\-t\fR) are passed to \fBls\fR(1) which produces the actual output\.
.
.TP
\fB\-\-unbrewed\fR
-List all files in the Homebrew prefix not installed by Homebrew\.
+List files in Homebrew\'s prefix not installed by Homebrew\.
.
.TP
\fB\-\-versions\fR
-Show the version number for installed formulae, or only the specified formulae if \fIformula\fR are given\.
+Show the version number for installed formulae, or only the specified formulae if \fIformula\fR are provided\.
.
.TP
\fB\-\-multiple\fR
Only show formulae with multiple versions installed\.
.
.TP
\fB\-\-pinned\fR
-Show the versions of pinned formulae, or only the specified (pinned) formulae if \fIformula\fR are given\. See also \fBpin\fR, \fBunpin\fR\.
+Show the versions of pinned formulae, or only the specified (pinned) formulae if \fIformula\fR are provided\. See also \fBpin\fR, \fBunpin\fR\.
.
.TP
\fB\-1\fR
Force output to be one entry per line\. This is the default when output is not to a terminal\.
.
.TP
\fB\-l\fR
-List in long format\. If the output is to a terminal, a total sum for all the file sizes is output on a line before the long listing\.
+List in long format\. If the output is to a terminal, a total sum for all the file sizes is printed before the long listing\.
.
.TP
\fB\-r\fR
-Reverse the order of the sort to get the oldest entries first\.
+Reverse the order of the sort to list the oldest entries first\.
.
.TP
\fB\-t\fR
-Sort by time modified (most recently modified first)\.
+Sort by time modified, listing most recently modified first\.
.
-.SS "\fBlog\fR [\fIoptions\fR] \fIformula\fR"
-Show the \fBgit log\fR for the given \fIformula\fR\.
+.SS "\fBlog\fR [\fIoptions\fR] [\fIformula\fR]"
+Show the \fBgit log\fR for \fIformula\fR, or show the log for the Homebrew repository if no formula is provided\.
.
.TP
\fB\-p\fR, \fB\-\-patch\fR
-Also output patch from commit\.
+Also print patch from commit\.
.
.TP
\fB\-\-stat\fR
-Also output diffstat from commit\.
+Also print diffstat from commit\.
.
.TP
\fB\-\-oneline\fR
-Output only one line per commit\.
+Print only one line per commit\.
.
.TP
\fB\-1\fR, \fB\-\-max\-count\fR
-Output only one commit\.
+Print only one or a specified number of commits\.
.
.SS "\fBmigrate\fR [\fIoptions\fR] \fIformula\fR"
-Migrate renamed packages to new name, where \fIformula\fR are old names of packages\.
+Migrate renamed packages to new names, where \fIformula\fR are old names of packages\.
.
-.SS "\fBmissing\fR [\fIoptions\fR] [\fIformulae\fR]"
-Check the given \fIformula\fR for missing dependencies\. If no \fIformula\fR are given, check all installed brews\.
-.
-.P
-\fBmissing\fR exits with a non\-zero status if any formulae are missing dependencies\.
+.SS "\fBmissing\fR [\fIoptions\fR] [\fIformula\fR]"
+Check the given \fIformula\fR kegs for missing dependencies\. If no \fIformula\fR are provided, check all kegs\. Will exit with a non\-zero status if any kegs are found to be missing dependencies\.
.
.TP
\fB\-\-hide\fR
-Act as if none of the provided \fIhidden\fR are installed\. \fIhidden\fR should be comma\-separated list of formulae\.
+Act as if none of the specified \fIhidden\fR are installed\. \fIhidden\fR should be a comma\-separated list of formulae\.
.
-.SS "\fBoptions\fR [\fIoptions\fR] \fIformula\fR"
-Display install options specific to \fIformula\fR
+.SS "\fBoptions\fR [\fIoptions\fR] [\fIformula\fR]"
+Show install options specific to \fIformula\fR\.
.
.TP
\fB\-\-compact\fR
Show all options on a single line separated by spaces\.
.
.TP
-\fB\-\-all\fR
-Show options for all formulae\.
+\fB\-\-installed\fR
+Show options for formulae that are currently installed\.
.
.TP
-\fB\-\-installed\fR
-Show options for all installed formulae\.
+\fB\-\-all\fR
+Show options for all available formulae\.
.
.SS "\fBoutdated\fR [\fIoptions\fR]"
-Show formulae that have an updated version available\.
-.
-.P
-By default, version information is displayed in interactive shells, and suppressed otherwise\.
+List installed formulae that have an updated version available\. By default, version information is displayed in interactive shells, and suppressed otherwise\.
.
.TP
\fB\-\-json\fR
Print output in JSON format\. Currently the default and only accepted value for \fIversion\fR is \fBv1\fR\. See the docs for examples of using the JSON output: \fIhttps://docs\.brew\.sh/Querying\-Brew\fR
.
.TP
\fB\-\-fetch\-HEAD\fR
-Fetch the upstream repository to detect if the HEAD installation of the formula is outdated\. Otherwise, the repository\'s HEAD will be checked for updates when a new stable or development version has been released\.
+Fetch the upstream repository to detect if the HEAD installation of the formula is outdated\. Otherwise, the repository\'s HEAD will only be checked for updates when a new stable or development version has been released\.
.
.SS "\fBpin\fR \fIformula\fR"
Pin the specified \fIformula\fR, preventing them from being upgraded when issuing the \fBbrew upgrade\fR \fIformula\fR command\. See also \fBunpin\fR\.
@@ -458,7 +449,7 @@ Pin the specified \fIformula\fR, preventing them from being upgraded when issuin
Rerun the post\-install steps for \fIformula\fR\.
.
.SS "\fBreadall\fR [\fIoptions\fR] [\fItap\fR]"
-Import all formulae from specified \fItap\fR (defaults to all installed taps)\. This can be useful for debugging issues across all formulae when making significant changes to \fBformula\.rb\fR, testing the performance of loading all formulae or to determine if any current formulae have Ruby issues\.
+Import all formulae from the specified \fItap\fR, or from all installed taps if none is provided\. This can be useful for debugging issues across all formulae when making significant changes to \fBformula\.rb\fR, testing the performance of loading all formulae or to determine if any current formulae have Ruby issues\.
.
.TP
\fB\-\-aliases\fR
@@ -469,10 +460,10 @@ Verify any alias symlinks in each tap\.
Syntax\-check all of Homebrew\'s Ruby files\.
.
.SS "\fBreinstall\fR [\fIoptions\fR] \fIformula\fR"
-Uninstall and then install \fIformula\fR (with existing and any appended install options)\.
+Uninstall and then install \fIformula\fR using the same options it was originally installed with, plus any appended brew formula options\.
.
.P
-Unless \fBHOMEBREW_NO_INSTALL_CLEANUP\fR is set, \fBbrew cleanup\fR will be run for the reinstalled formulae or, every 30 days, for all formulae\.
+Unless \fBHOMEBREW_NO_INSTALL_CLEANUP\fR is set, \fBbrew cleanup\fR will then be run for the reinstalled formulae or, every 30 days, for all formulae\.
.
.TP
\fB\-s\fR, \fB\-\-build\-from\-source\fR
@@ -484,25 +475,25 @@ Install from a bottle if it exists for the current or newest version of macOS, e
.
.TP
\fB\-\-keep\-tmp\fR
-Don\'t delete the temporary files created during installation\.
+Retain the temporary files created during installation\.
.
.TP
\fB\-\-display\-times\fR
Print install times for each formula at the end of the run\.
.
.SS "\fBsearch\fR [\fIoptions\fR] [\fItext\fR|\fB/\fR\fItext\fR\fB/\fR]"
-Perform a substring search of cask tokens and formula names for \fItext\fR\. If \fItext\fR is surrounded with slashes, then it is interpreted as a regular expression\. The search for \fItext\fR is extended online to \fBhomebrew/core\fR and \fBhomebrew/cask\fR\.
+Perform a substring search of cask tokens and formula names for \fItext\fR\. If \fItext\fR is flanked by slashes, it is interpreted as a regular expression\. The search for \fItext\fR is extended online to \fBhomebrew/core\fR and \fBhomebrew/cask\fR\.
.
.P
-If no \fItext\fR is passed, display all locally available formulae (including tapped ones)\. No online search is performed\.
+If no \fItext\fR is provided, list all locally available formulae (including tapped ones)\. No online search is performed\.
.
.TP
\fB\-\-casks\fR
-Display all locally available casks (including tapped ones)\. No online search is performed\.
+List all locally available casks (including tapped ones)\. No online search is performed\.
.
.TP
\fB\-\-desc\fR
-search formulae with a description matching \fItext\fR and casks with a name matching \fItext\fR\.
+Search for formulae with a description matching \fItext\fR and casks with a name matching \fItext\fR\.
.
.TP
\fB\-\-macports\fR
@@ -529,20 +520,20 @@ Search for \fItext\fR in the given package manager\'s list\.
Search for \fItext\fR in the given package manager\'s list\.
.
.SS "\fBsh\fR [\fIoptions\fR]"
-Start a Homebrew build environment shell\. Uses our years\-battle\-hardened Homebrew build logic to help your \fB\./configure && make && make install\fR or even your \fBgem install\fR succeed\. Especially handy if you run Homebrew in an Xcode\-only configuration since it adds tools like \fBmake\fR to your \fBPATH\fR which otherwise build systems would not find\.
+Start a Homebrew build environment shell\. Uses our years\-battle\-hardened Homebrew build logic to help your \fB\./configure && make && make install\fR or even your \fBgem install\fR succeed\. Especially handy if you run Homebrew in an Xcode\-only configuration since it adds tools like \fBmake\fR to your \fBPATH\fR which build systems would not find otherwise\.
.
.TP
\fB\-\-env\fR
-Use the standard \fBPATH\fR instead of superenv\'s, when \fIstd\fR is passed
+Use the standard \fBPATH\fR instead of superenv\'s when \fBstd\fR is passed\.
.
.SS "\fBshellenv\fR"
-Prints export statements \- run them in a shell and this installation of Homebrew will be included into your \fBPATH\fR, \fBMANPATH\fR and \fBINFOPATH\fR\.
+Print export statements\. When run in a shell, this installation of Homebrew will be added to your \fBPATH\fR, \fBMANPATH\fR, and \fBINFOPATH\fR\.
.
.P
-\fBHOMEBREW_PREFIX\fR, \fBHOMEBREW_CELLAR\fR and \fBHOMEBREW_REPOSITORY\fR are also exported to save multiple queries of those variables\.
+The variables \fBHOMEBREW_PREFIX\fR, \fBHOMEBREW_CELLAR\fR and \fBHOMEBREW_REPOSITORY\fR are also exported to avoid querying them multiple times\.
.
.P
-Consider adding evaluating the output in your dotfiles (e\.g\. \fB~/\.profile\fR) with \fBeval $(brew shellenv)\fR
+Consider adding evaluation of this command\'s output to your dotfiles (e\.g\. \fB~/\.profile\fR) with: \fBeval $(brew shellenv)\fR
.
.SS "\fBstyle\fR [\fIoptions\fR] [\fIfile\fR|\fItap\fR|\fIformula\fR]"
Check formulae or files for conformance to Homebrew style guidelines\.
@@ -567,23 +558,23 @@ Specify a comma\-separated \fIcops\fR list to check for violations of only the l
Specify a comma\-separated \fIcops\fR list to skip checking for violations of the listed RuboCop cops\.
.
.SS "\fBswitch\fR \fIformula\fR \fIversion\fR"
-Symlink all of the specific \fIversion\fR of \fIformula\fR\'s install to Homebrew prefix\.
+Symlink all of the specified \fIversion\fR of \fIformula\fR\'s installation into Homebrew\'s prefix\.
.
.SS "\fBtap\fR [\fIoptions\fR] \fIuser\fR\fB/\fR\fIrepo\fR [\fIURL\fR]"
Tap a formula repository\.
.
.P
-List all installed taps when no arguments are passed\.
+If no arguments are provided, list all installed taps\.
.
.P
-With \fIURL\fR unspecified, taps a formula repository from GitHub using HTTPS\. Since so many taps are hosted on GitHub, this command is a shortcut for \fBbrew tap\fR \fIuser\fR\fB/\fR\fIrepo\fR \fBhttps://github\.com/\fR\fIuser\fR\fB/homebrew\-\fR\fIrepo\fR\.
+With \fIURL\fR unspecified, tap a formula repository from GitHub using HTTPS\. Since so many taps are hosted on GitHub, this command is a shortcut for \fBbrew tap\fR \fIuser\fR\fB/\fR\fIrepo\fR \fBhttps://github\.com/\fR\fIuser\fR\fB/homebrew\-\fR\fIrepo\fR\.
.
.P
-With \fIURL\fR specified, taps a formula repository from anywhere, using any transport protocol that \fBgit\fR handles\. The one\-argument form of \fBtap\fR 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\.
+With \fIURL\fR specified, tap a formula repository from anywhere, using any transport protocol that \fBgit\fR(1) handles\. The one\-argument form of \fBtap\fR 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\.
.
.TP
\fB\-\-full\fR
-Use a full clone when tapping a repository\. By default, the repository is cloned as a shallow copy (\fB\-\-depth=1\fR)\. To convert a shallow copy to a full copy, you can retap passing \fB\-\-full\fR without first untapping\.
+Use a full clone when tapping a repository\. By default, the repository is cloned as a shallow copy (\fB\-\-depth=1\fR)\. To convert a shallow copy to a full copy, you can retap by passing \fB\-\-full\fR without first untapping\.
.
.TP
\fB\-\-force\-auto\-update\fR
@@ -602,15 +593,18 @@ List all pinned taps\.
Suppress any warnings\.
.
.SS "\fBtap\-info\fR [\fIoptions\fR] [\fItap\fR]"
-Display detailed information about one or more provided \fItap\fR\. Display a brief summary of all installed taps if no \fItap\fR are passed\.
+Show detailed information about one or more \fItap\fRs\.
+.
+.P
+If no \fItap\fR names are provided, display brief statistics for all installed taps\.
.
.TP
\fB\-\-installed\fR
-Display information on all installed taps\.
+Show information on each installed tap\.
.
.TP
\fB\-\-json\fR
-Print a JSON representation of \fItaps\fR\. Currently the default and only accepted value for \fIversion\fR is \fBv1\fR\. See the docs for examples of using the JSON output: \fIhttps://docs\.brew\.sh/Querying\-Brew\fR
+Print a JSON representation of \fItap\fR\. Currently the default and only accepted value for \fIversion\fR is \fBv1\fR\. See the docs for examples of using the JSON output: \fIhttps://docs\.brew\.sh/Querying\-Brew\fR
.
.SS "\fBuninstall\fR, \fBrm\fR, \fBremove\fR [\fIoptions\fR] \fIformula\fR"
Uninstall \fIformula\fR\.
@@ -620,11 +614,11 @@ Uninstall \fIformula\fR\.
Don\'t fail uninstall, even if \fIformula\fR is a dependency of any installed formulae\.
.
.SS "\fBunlink\fR [\fIoptions\fR] \fIformula\fR"
-Remove symlinks for \fIformula\fR from the Homebrew prefix\. This can be useful for temporarily disabling a formula: \fBbrew unlink\fR \fIformula\fR \fB&&\fR \fIcommands\fR \fB&& brew link\fR \fIformula\fR
+Remove symlinks for \fIformula\fR from Homebrew\'s prefix\. This can be useful for temporarily disabling a formula: \fBbrew unlink\fR \fIformula\fR \fB&&\fR \fIcommands\fR \fB&& brew link\fR \fIformula\fR
.
.TP
\fB\-n\fR, \fB\-\-dry\-run\fR
-List all files which would be unlinked, but will not actually unlink or delete any files\.
+List files which would be unlinked without actually unlinking or deleting any files\.
.
.SS "\fBunpack\fR [\fIoptions\fR] \fIformula\fR"
Unpack the source files for \fIformula\fR into subdirectories of the current working directory\.
@@ -645,26 +639,26 @@ Initialise a Git repository in the unpacked source\. This is useful for creating
Unpin \fIformula\fR, allowing them to be upgraded by \fBbrew upgrade\fR \fIformula\fR\. See also \fBpin\fR\.
.
.SS "\fBuntap\fR \fItap\fR"
-Remove a tapped repository\.
+Remove a tapped formula repository\.
.
-.SS "\fBupdate\fR [\fIoptions\fR]"
+.SS "\fBupdate\fR, \fBup\fR [\fIoptions\fR]"
Fetch the newest version of Homebrew and all formulae from GitHub using \fBgit\fR(1) and perform any necessary migrations\.
.
.TP
\fB\-\-merge\fR
-\fBgit merge\fR is used to include updates (rather than \fBgit rebase\fR)\.
+Use \fBgit merge\fR to apply updates (rather than \fBgit rebase\fR)\.
.
.SS "\fBupdate\-reset\fR [\fIrepository\fR]"
-Fetches and resets Homebrew and all tap repositories (or any specified \fBrepository\fR) using \fBgit\fR(1) to their latest \fBorigin/master\fR\. Note this will destroy all your uncommitted or committed changes\.
-.
-.SS "\fBupgrade\fR [\fIoptions\fR] \fIformula\fR"
-Upgrade outdated, unpinned formulae (with existing and any appended brew formula options)\.
+Fetch and reset Homebrew and all tap repositories (or any specified \fIrepository\fR) using \fBgit\fR(1) to their latest \fBorigin/master\fR\.
.
.P
-If \fIformula\fR are given, upgrade only the specified brews (unless they are pinned; see \fBpin\fR, \fBunpin\fR)\.
+\fINote:\fR this will destroy all your uncommitted or committed changes\.
+.
+.SS "\fBupgrade\fR [\fIoptions\fR] [\fIformula\fR]"
+Upgrade outdated, unpinned formulae using the same options they were originally installed with, plus any appended brew formula options\. If \fIformula\fR are specified, upgrade only the given \fIformula\fR kegs (unless they are pinned; see \fBpin\fR, \fBunpin\fR)\.
.
.P
-Unless \fBHOMEBREW_NO_INSTALL_CLEANUP\fR is set, \fBbrew cleanup\fR will be run for the upgraded formulae or, every 30 days, for all formulae\.
+Unless \fBHOMEBREW_NO_INSTALL_CLEANUP\fR is set, \fBbrew cleanup\fR will then be run for the upgraded formulae or, every 30 days, for all formulae\.
.
.TP
\fB\-s\fR, \fB\-\-build\-from\-source\fR
@@ -676,15 +670,15 @@ Install from a bottle if it exists for the current or newest version of macOS, e
.
.TP
\fB\-\-fetch\-HEAD\fR
-Fetch the upstream repository to detect if the HEAD installation of the formula is outdated\. Otherwise, the repository\'s HEAD will be checked for updates when a new stable or development version has been released\.
+Fetch the upstream repository to detect if the HEAD installation of the formula is outdated\. Otherwise, the repository\'s HEAD will only be checked for updates when a new stable or development version has been released\.
.
.TP
\fB\-\-ignore\-pinned\fR
-Set a 0 exit code even if pinned formulae are not upgraded\.
+Set a successful exit status even if pinned formulae are not upgraded\.
.
.TP
\fB\-\-keep\-tmp\fR
-Don\'t delete the temporary files created during installation\.
+Retain the temporary files created during installation\.
.
.TP
\fB\-\-display\-times\fR
@@ -695,21 +689,15 @@ Print install times for each formula at the end of the run\.
Show what would be upgraded, but do not actually upgrade anything\.
.
.SS "\fBuses\fR [\fIoptions\fR] \fIformula\fR"
-Show the formulae that specify \fIformula\fR as a dependency\. When given multiple formula arguments, show the intersection of formulae that use \fIformula\fR\.
-.
-.P
-By default, \fBuses\fR shows all formulae that specify \fIformula\fR as a required or recommended dependency\.
-.
-.P
-By default, \fBuses\fR shows usage of \fIformula\fR by stable builds\.
+Show formulae that specify \fIformula\fR as a dependency\. When given multiple formula arguments, show the intersection of formulae that use \fIformula\fR\. By default, \fBuses\fR shows all formulae that specify \fIformula\fR as a required or recommended dependency for their stable builds\.
.
.TP
\fB\-\-recursive\fR
Resolve more than one level of dependencies\.
.
.TP
\fB\-\-installed\fR
-Only list installed formulae\.
+Only list formulae that are currently installed\.
.
.TP
\fB\-\-include\-build\fR
@@ -729,11 +717,11 @@ Skip all formulae that specify \fIformula\fR as \fB:recommended\fR type dependen
.
.TP
\fB\-\-devel\fR
-Show usage of \fIformula\fR by development build\.
+Show usage of \fIformula\fR by development builds\.
.
.TP
\fB\-\-HEAD\fR
-Show usage of \fIformula\fR by HEAD build\.
+Show usage of \fIformula\fR by HEAD builds\.
.
.SS "\fB\-\-cache\fR [\fIoptions\fR] [\fIformula\fR]"
Display Homebrew\'s download cache\. See also \fBHOMEBREW_CACHE\fR\.
@@ -756,7 +744,7 @@ Display Homebrew\'s Cellar path\. \fIDefault:\fR \fB$(brew \-\-prefix)/Cellar\fR
If \fIformula\fR is provided, display the location in the cellar where \fIformula\fR would be installed, without any sort of versioned directory as the last path\.
.
.SS "\fB\-\-env\fR [\fIoptions\fR]"
-Show a summary of the Homebrew build environment as a plain list\.
+Summarize Homebrew\'s build environment as a plain list\.
.
.P
If the command\'s output is sent through a pipe and no shell is specified, the list is formatted for export to \fBbash\fR(1) unless \fB\-\-plain\fR is passed\.
@@ -767,27 +755,27 @@ Generate a list of environment variables for the specified shell, or \fB\-\-shel
.
.TP
\fB\-\-plain\fR
-Plain output even when piped\.
+Generate plain output even when piped\.
.
.SS "\fB\-\-prefix\fR [\fIformula\fR]"
Display Homebrew\'s install path\. \fIDefault:\fR \fB/usr/local\fR on macOS and \fB/home/linuxbrew/\.linuxbrew\fR on Linux\.
.
.P
If \fIformula\fR is provided, display the location in the cellar where \fIformula\fR is or would be installed\.
.
-.SS "\fB\-\-repository\fR [\fIuser\fR\fB/\fR\fIrepo\fR]"
+.SS "\fB\-\-repository\fR, \fB\-\-repo\fR [\fIuser\fR\fB/\fR\fIrepo\fR]"
Display where Homebrew\'s \fB\.git\fR directory is located\.
.
.P
If \fIuser\fR\fB/\fR\fIrepo\fR are provided, display where tap \fIuser\fR\fB/\fR\fIrepo\fR\'s directory is located\.
.
.SS "\fB\-\-version\fR"
-Print the version number of Homebrew, Homebrew/homebrew\-core and Homebrew/homebrew\-cask (if tapped) to standard output and exit\.
+Print the version numbers of Homebrew, Homebrew/homebrew\-core and Homebrew/homebrew\-cask (if tapped) to standard output\.
.
.SH "DEVELOPER COMMANDS"
.
-.SS "\fBaudit\fR [\fIoptions\fR] \fIformula\fR"
-Check \fIformula\fR for Homebrew coding style violations\. This should be run before submitting a new formula\. Will exit with a non\-zero status if any errors are found, which can be useful for implementing pre\-commit hooks\. If no \fIformula\fR are provided, all of them are checked\.
+.SS "\fBaudit\fR [\fIoptions\fR] [\fIformula\fR]"
+Check \fIformula\fR for Homebrew coding style violations\. This should be run before submitting a new formula\. If no \fIformula\fR are provided, check all locally available formulae\. Will exit with a non\-zero status if any errors are found, which can be useful for implementing pre\-commit hooks\.
.
.TP
\fB\-\-strict\fR
@@ -811,7 +799,7 @@ Include the RuboCop cop name for each violation in the output\.
.
.TP
\fB\-\-display\-filename\fR
-Prefix every line of output with name of the file or formula being audited, to make output easy to grep\.
+Prefix every line of output with the file or formula name being audited, to make output easy to grep\.
.
.TP
\fB\-D\fR, \fB\-\-audit\-debug\fR
@@ -858,15 +846,15 @@ If the formula specifies a rebuild version, attempt to preserve its value in the
.
.TP
\fB\-\-json\fR
-Write bottle information to a JSON file, which can be used as the argument for \fB\-\-merge\fR\.
+Write bottle information to a JSON file, which can be used as the value for \fB\-\-merge\fR\.
.
.TP
\fB\-\-merge\fR
-Generate an updated bottle block for a formula and optionally merge it into the formula file\. Instead of a formula name, requires a JSON file generated with \fBbrew bottle \-\-json\fR \fIformula\fR\.
+Generate an updated bottle block for a formula and optionally merge it into the formula file\. Instead of a formula name, requires the path to a JSON file generated with \fBbrew bottle \-\-json\fR \fIformula\fR\.
.
.TP
\fB\-\-write\fR
-Write the changes to the formula file\. A new commit will be generated unless \fB\-\-no\-commit\fR is passed\.
+Write changes to the formula file\. A new commit will be generated unless \fB\-\-no\-commit\fR is passed\.
.
.TP
\fB\-\-no\-commit\fR
@@ -877,7 +865,7 @@ When passed with \fB\-\-write\fR, a new commit will not generated after writing
Use the specified \fIURL\fR as the root of the bottle\'s URL instead of Homebrew\'s default\.
.
.SS "\fBbump\-formula\-pr\fR [\fIoptions\fR] [\fIformula\fR]"
-Create a pull request to update a formula with a new URL or a new tag\.
+Create a pull request to update \fIformula\fR with a new URL or a new tag\.
.
.P
If a \fIURL\fR is specified, the \fISHA\-256\fR checksum of the new download should also be specified\. A best effort to determine the \fISHA\-256\fR and \fIformula\fR name will be made if either or both values are not supplied by the user\.
@@ -886,7 +874,7 @@ If a \fIURL\fR is specified, the \fISHA\-256\fR checksum of the new download sho
If a \fItag\fR is specified, the Git commit \fIrevision\fR corresponding to that tag must also be specified\.
.
.P
-\fINote:\fR this command cannot be used to transition a formula from a URL\-and\-SHA\-256 style specification into a tag\-and\-revision style specification, nor vice versa\. It must use whichever style specification the preexisting formula already uses\.
+\fINote:\fR this command cannot be used to transition a formula from a URL\-and\-SHA\-256 style specification into a tag\-and\-revision style specification, nor vice versa\. It must use whichever style specification the formula already uses\.
.
.TP
\fB\-\-devel\fR
@@ -914,15 +902,15 @@ Print the pull request URL instead of opening in a browser\.
.
.TP
\fB\-\-mirror\fR
-Use the provided \fIURL\fR as a mirror URL\.
+Use the specified \fIURL\fR as a mirror URL\.
.
.TP
\fB\-\-version\fR
-Use the provided \fIversion\fR to override the value parsed from the URL or tag\. Note that \fB\-\-version=0\fR can be used to delete an existing version override from a formula if it has become redundant\.
+Use the specified \fIversion\fR to override the value parsed from the URL or tag\. Note that \fB\-\-version=0\fR can be used to delete an existing version override from a formula if it has become redundant\.
.
.TP
\fB\-\-message\fR
-Append the provided \fImessage\fR to the default PR message\.
+Append \fImessage\fR to the default pull request message\.
.
.TP
\fB\-\-url\fR
@@ -938,18 +926,18 @@ Specify the new git commit \fItag\fR for the formula\.
.
.TP
\fB\-\-revision\fR
-Specify the new git commit \fIrevision\fR corresponding to a specified \fItag\fR\.
+Specify the new git commit \fIrevision\fR corresponding to the specified \fItag\fR\.
.
-.SS "\fBbump\-revision\fR [\fIoptions\fR] [\fIformula\fR]"
-Create a commit to increment the revision of the formula\. If no revision is present, "revision 1" will be added\.
+.SS "\fBbump\-revision\fR [\fIoptions\fR] \fIformula\fR"
+Create a commit to increment the revision of \fIformula\fR\. If no revision is present, "revision 1" will be added\.
.
.TP
\fB\-n\fR, \fB\-\-dry\-run\fR
Print what would be done rather than doing it\.
.
.TP
\fB\-\-message\fR
-Append the provided \fImessage\fR to the default commit message\.
+Append \fImessage\fR to the default commit message\.
.
.SS "\fBcreate\fR [\fIoptions\fR] \fIURL\fR"
Generate a formula for the downloadable file at \fIURL\fR and open it in the editor\. Homebrew will attempt to automatically derive the formula name and version, but if it fails, you\'ll have to make your own template\. The \fBwget\fR formula serves as a simple example\. For the complete API, see: \fIhttp://www\.rubydoc\.info/github/Homebrew/brew/master/Formula\fR
@@ -968,36 +956,36 @@ Create a basic template for a Meson\-style build\.
.
.TP
\fB\-\-no\-fetch\fR
-Homebrew will not download \fIURL\fR to the cache and will thus not add the SHA\-256 to the formula for you, nor will it check the GitHub API for GitHub projects (to fill out its description and homepage)\.
+Homebrew will not download \fIURL\fR to the cache and will thus not add its SHA\-256 to the formula for you, nor will it check the GitHub API for GitHub projects (to fill out its description and homepage)\.
.
.TP
\fB\-\-HEAD\fR
Indicate that \fIURL\fR points to the package\'s repository rather than a file\.
.
.TP
\fB\-\-set\-name\fR
-Set the name of the new formula to the provided \fIname\fR\.
+Explicitly set the \fIname\fR of the new formula\.
.
.TP
\fB\-\-set\-version\fR
-Set the version of the new formula to the provided \fIversion\fR\.
+Explicitly set the \fIversion\fR of the new formula\.
.
.TP
\fB\-\-tap\fR
-Generate the new formula in the provided tap, specified as \fIuser\fR\fB/\fR\fIrepo\fR\.
+Generate the new formula within the given tap, specified as \fIuser\fR\fB/\fR\fIrepo\fR\.
.
.SS "\fBedit\fR [\fIformula\fR]"
-Open a formula in the editor set by \fBEDITOR\fR or \fBHOMEBREW_EDITOR\fR, or open the Homebrew repository for editing if no \fIformula\fR is provided\.
+Open \fIformula\fR in the editor set by \fBEDITOR\fR or \fBHOMEBREW_EDITOR\fR, or open the Homebrew repository for editing if no formula is provided\.
.
.SS "\fBextract\fR [\fIoptions\fR] \fIformula\fR \fItap\fR"
-Look through repository history to find the most recent version of \fIformula\fR and create a copy in \fItap\fR\fB/Formula/\fR\fIformula\fR\fB@\fR\fIversion\fR\fB\.rb\fR\. If the tap is not installed yet, attempt to install/clone the tap before continuing\. To extract a \fIformula\fR from a tap that is not homebrew/core use \fIuser\fR/\fIrepo\fR/\fIformula\fR\.
+Look through repository history to find the most recent version of \fIformula\fR and create a copy in \fItap\fR\fB/Formula/\fR\fIformula\fR\fB@\fR\fIversion\fR\fB\.rb\fR\. If the tap is not installed yet, attempt to install/clone the tap before continuing\. To extract a formula from a tap that is not \fBhomebrew/core\fR use its fully\-qualified form of \fIuser\fR\fB/\fR\fIrepo\fR\fB/\fR\fIformula\fR\.
.
.TP
\fB\-\-version\fR
-Extract the provided \fIversion\fR of \fIformula\fR instead of the most recent\.
+Extract the specified \fIversion\fR of \fIformula\fR instead of the most recent\.
.
.SS "\fBformula\fR \fIformula\fR"
-Display the path where a formula is located\.
+Display the path where \fIformula\fR is located\.
.
.SS "\fBirb\fR [\fIoptions\fR]"
Enter the interactive Homebrew Ruby shell\.
@@ -1011,11 +999,11 @@ Show several examples\.
Use Pry instead of IRB\. Implied if \fBHOMEBREW_PRY\fR is set\.
.
.SS "\fBlinkage\fR [\fIoptions\fR] [\fIformula\fR]"
-Check the library links for kegs of installed formulae\. Raises an error if run on uninstalled formulae\.
+Check the library links from the given \fIformula\fR kegs\. If no \fIformula\fR are provided, check all kegs\. Raises an error if run on uninstalled formulae\.
.
.TP
\fB\-\-test\fR
-Display only missing libraries and exit with a non\-zero status if any missing libraries are found\.
+Show only missing libraries and exit with a non\-zero status if any missing libraries are found\.
.
.TP
\fB\-\-reverse\fR
@@ -1030,20 +1018,20 @@ Generate Homebrew\'s manpages\.
.
.TP
\fB\-\-fail\-if\-changed\fR
-Return a failing status code if changes are detected in the manpage outputs\. This can be used for CI to be notified when the manpages are out of date\. Additionally, the date used in new manpages will match those in the existing manpages (to allow comparison without factoring in the date)\.
+Return a failing status code if changes are detected in the manpage outputs\. This can be used to notify CI when the manpages are out of date\. Additionally, the date used in new manpages will match those in the existing manpages (to allow comparison without factoring in the date)\.
.
.TP
\fB\-\-link\fR
This is now done automatically by \fBbrew update\fR\.
.
.SS "\fBprof\fR \fIcommand\fR"
-Run Homebrew with the Ruby profiler e\.g\. \fBbrew prof readall\fR\.
+Run Homebrew with the Ruby profiler, e\.g\. \fBbrew prof readall\fR\.
.
.SS "\fBpull\fR [\fIoptions\fR] \fIpatch\fR"
-Get a patch from a GitHub commit or pull request and apply it to Homebrew\. Optionally, publish updated bottles for the formulae changed by the patch\.
+Get a patch from a GitHub commit or pull request and apply it to Homebrew\. Optionally, publish updated bottles for any formulae changed by the patch\.
.
.P
-Each \fIpatch\fR may be the number of a PR in \fBhomebrew/core\fR, the URL of a PR on GitHub, the URL of a commit on GitHub or a "https://jenkins\.brew\.sh/job/\.\.\." testing job URL\.
+Each \fIpatch\fR may be the number of a pull request in \fBhomebrew/core\fR, the URL of any pull request or commit on GitHub or a "https://jenkins\.brew\.sh/job/\.\.\." testing job URL\.
.
.TP
\fB\-\-bottle\fR
@@ -1083,11 +1071,11 @@ Do not exit if there\'s a failure publishing bottles on Bintray\.
.
.TP
\fB\-\-bintray\-org\fR
-Publish bottles at the provided Bintray \fIorganisation\fR\.
+Publish bottles to the specified Bintray \fIorganisation\fR\.
.
.TP
\fB\-\-test\-bot\-user\fR
-Pull the bottle block commit from the provided \fIuser\fR on GitHub\.
+Pull the bottle block commit from the specified \fIuser\fR on GitHub\.
.
.SS "\fBrelease\-notes\fR [\fIoptions\fR] [\fIprevious_tag\fR] [\fIend_ref\fR]"
Print the merged pull requests on Homebrew/brew between two Git refs\. If no \fIprevious_tag\fR is provided it defaults to the latest tag\. If no \fIend_ref\fR is provided it defaults to \fBorigin/master\fR\.
@@ -1096,12 +1084,12 @@ Print the merged pull requests on Homebrew/brew between two Git refs\. If no \fI
\fB\-\-markdown\fR
Print as a Markdown list\.
.
-.SS "\fBruby\fR [\fB\-e\fR]:"
-Run a Ruby instance with Homebrew\'s libraries loaded e\.g\. \fBbrew ruby \-e "puts :gcc\.f\.deps"\fR or \fBbrew ruby script\.rb\fR
+.SS "\fBruby\fR (\fB\-e\fR \fItext\fR|\fIfile\fR)"
+Run a Ruby instance with Homebrew\'s libraries loaded, e\.g\. \fBbrew ruby \-e "puts :gcc\.f\.deps"\fR or \fBbrew ruby script\.rb\fR\.
.
.TP
\fB\-e\fR
-Execute the provided string argument as a script\.
+Execute the given text string as a script\.
.
.SS "\fBtap\-new\fR \fIuser\fR\fB/\fR\fIrepo\fR"
Generate the template files for a new tap\.
@@ -1122,7 +1110,7 @@ Test the head version of a formula\.
.
.TP
\fB\-\-keep\-tmp\fR
-Keep the temporary files created for the test\.
+Retain the temporary files created for the test\.
.
.SS "\fBtests\fR [\fIoptions\fR]"
Run Homebrew\'s unit and integration tests\.
@@ -1149,10 +1137,10 @@ Run only \fItest_script\fR\fB_spec\.rb\fR\. Appending \fB:\fR\fIline_number\fR w
.
.TP
\fB\-\-seed\fR
-Randomise tests with the provided \fIvalue\fR instead of a random seed\.
+Randomise tests with the specified \fIvalue\fR instead of a random seed\.
.
.SS "\fBupdate\-test\fR [\fIoptions\fR]"
-Run a test of \fBbrew update\fR with a new repository clone\. If no arguments are passed, use \fBorigin/master\fR as the start commit\.
+Run a test of \fBbrew update\fR with a new repository clone\. If no options are passed, use \fBorigin/master\fR as the start commit\.
.
.TP
\fB\-\-to\-tag\fR
@@ -1164,11 +1152,11 @@ Retain the temporary directory containing the new repository clone\.
.
.TP
\fB\-\-commit\fR
-Use provided \fIcommit\fR as the start commit\.
+Use the specified \fIcommit\fR as the start commit\.
.
.TP
\fB\-\-before\fR
-Use the commit at provided \fIdate\fR as the start commit\.
+Use the commit at the specified \fIdate\fR as the start commit\.
.
.SS "\fBvendor\-gems\fR"
Install and commit Homebrew\'s vendored gems\.
@@ -1202,7 +1190,7 @@ Bundler for non\-Ruby dependencies from Homebrew, Homebrew Cask and the Mac App
\fIhttps://github\.com/Homebrew/homebrew\-bundle\fR
.
.SS "\fBcask\fR \fIsubcommand\fR:"
-Install macOS applications distributed as binaries\. See brew\-cask(1)\.
+Install macOS applications distributed as binaries\. See \fBbrew\-cask\fR(1)\.
.
.P
\fBHomebrew/homebrew\-cask\fR
@@ -1234,10 +1222,10 @@ Sometimes a formula from a tapped repository may conflict with one in \fBhomebre
.
.TP
An arbitrary file or URL
-Homebrew can install formulae via URL, e\.g\. \fBhttps://raw\.githubusercontent\.com/Homebrew/homebrew\-core/master/Formula/git\.rb\fR, or from a local path\. It could point to either a formula file or a bottle\. In the case of a URL, the downloaded file will be cached for later use\.
+Homebrew can install formulae via URL, e\.g\. \fBhttps://raw\.githubusercontent\.com/Homebrew/homebrew\-core/master/Formula/git\.rb\fR, or from a local path\. It can point to either a formula file or a bottle\. In the case of a URL, the downloaded file will be cached for later use\.
.
.SH "ENVIRONMENT"
-Note that environment variables must have a value set to be detected\. For example, \fBexport HOMEBREW_NO_INSECURE_REDIRECT=1\fR rather than just \fBexport HOMEBREW_NO_INSECURE_REDIRECT\fR\.
+Note that environment variables must have a value set to be detected\. For example, run \fBexport HOMEBREW_NO_INSECURE_REDIRECT=1\fR rather than just \fBexport HOMEBREW_NO_INSECURE_REDIRECT\fR\.
.
.TP
\fBHOMEBREW_ARCH\fR
@@ -1275,7 +1263,7 @@ If set, instructs Homebrew to use the specified directory as the download cache\
.
.TP
\fBHOMEBREW_CURLRC\fR
-If set, Homebrew will not pass \fB\-q\fR when invoking \fBcurl\fR(1) (which disables the use of \fBcurlrc\fR)\.
+If set, Homebrew will not pass \fB\-q\fR when invoking \fBcurl\fR(1), which disables the use of \fBcurlrc\fR\.
.
.TP
\fBHOMEBREW_CURL_VERBOSE\fR
@@ -1321,7 +1309,7 @@ If set, Homebrew will always use its vendored, relocatable Ruby version even if
.
.TP
\fBHOMEBREW_FORCE_BREWED_GIT\fR
-If set, Homebrew will always use a Homebrew\-installed \fBgit\fR rather than the system version\. Automatically set if the system version of \fBgit\fR is too old\.
+If set, Homebrew will always use a Homebrew\-installed \fBgit\fR(1) rather than the system version\. Automatically set if the system version of \fBgit\fR is too old\.
.
.TP
\fBHOMEBREW_GITHUB_API_TOKEN\fR
@@ -1467,6 +1455,9 @@ export http_proxy=http://$USER:$PASSWORD@$HOST:$PORT
Homebrew Documentation: \fIhttps://docs\.brew\.sh\fR
.
.P
+Homebrew API: \fIhttps://rubydoc\.brew\.sh\fR
+.
+.P
\fBbrew\-cask\fR(1), \fBgit\fR(1), \fBgit\-log\fR(1)
.
.SH "AUTHORS" | true |
Other | Homebrew | brew | 329c6c78bece4a0c8211c5c3e4495ba2a9aeb81b.json | manpages: relocate some sections
Reorder switches as force/quiet/verbose/debug, --installed before --all, and link to SPECIFYING FORMULAE from top of page. | Library/Homebrew/cmd/fetch.rb | @@ -19,11 +19,11 @@ def fetch_args
description: "Fetch HEAD version instead of stable version."
switch "--devel",
description: "Fetch development version instead of stable version."
+ switch :force,
+ description: "Remove a previously cached version and re-fetch."
switch :verbose,
description: "Do a verbose VCS checkout, if the URL represents a VCS. This is useful for "\
"seeing if an existing VCS cache has been updated."
- switch :force,
- description: "Remove a previously cached version and re-fetch."
switch "--retry",
description: "Retry if a download fails or re-download if the checksum of a previously cached "\
"version no longer matches." | true |
Other | Homebrew | brew | 329c6c78bece4a0c8211c5c3e4495ba2a9aeb81b.json | manpages: relocate some sections
Reorder switches as force/quiet/verbose/debug, --installed before --all, and link to SPECIFYING FORMULAE from top of page. | Library/Homebrew/cmd/gist-logs.rb | @@ -17,9 +17,6 @@ def gist_logs_args
Upload logs for a failed build of <formula> to a new Gist.
- <formula> is usually the name of the formula to install, but it can be specified
- in several different ways.
-
If no logs are found, an error message is presented.
EOS
switch "--with-hostname", | true |
Other | Homebrew | brew | 329c6c78bece4a0c8211c5c3e4495ba2a9aeb81b.json | manpages: relocate some sections
Reorder switches as force/quiet/verbose/debug, --installed before --all, and link to SPECIFYING FORMULAE from top of page. | Library/Homebrew/cmd/install.rb | @@ -20,9 +20,6 @@ def install_args
Install <formula>.
- <formula> is usually the name of the formula to install, but it can be specified
- in several different ways.
-
Unless `HOMEBREW_NO_INSTALL_CLEANUP` is set, `brew cleanup` will be run for the
installed formulae or, every 30 days, for all formulae.
EOS | true |
Other | Homebrew | brew | 329c6c78bece4a0c8211c5c3e4495ba2a9aeb81b.json | manpages: relocate some sections
Reorder switches as force/quiet/verbose/debug, --installed before --all, and link to SPECIFYING FORMULAE from top of page. | Library/Homebrew/cmd/options.rb | @@ -16,12 +16,12 @@ def options_args
EOS
switch "--compact",
description: "Show all options on a single line separated by spaces."
- switch "--all",
- description: "Show options for all formulae."
switch "--installed",
description: "Show options for all installed formulae."
+ switch "--all",
+ description: "Show options for all available formulae."
switch :debug
- conflicts "--all", "--installed"
+ conflicts "--installed", "--all"
end
end
| true |
Other | Homebrew | brew | 329c6c78bece4a0c8211c5c3e4495ba2a9aeb81b.json | manpages: relocate some sections
Reorder switches as force/quiet/verbose/debug, --installed before --all, and link to SPECIFYING FORMULAE from top of page. | Library/Homebrew/cmd/postinstall.rb | @@ -14,8 +14,8 @@ def postinstall_args
Rerun the post-install steps for <formula>.
EOS
- switch :verbose
switch :force
+ switch :verbose
switch :debug
end
end | true |
Other | Homebrew | brew | 329c6c78bece4a0c8211c5c3e4495ba2a9aeb81b.json | manpages: relocate some sections
Reorder switches as force/quiet/verbose/debug, --installed before --all, and link to SPECIFYING FORMULAE from top of page. | Library/Homebrew/cmd/update-report.rb | @@ -29,8 +29,8 @@ def update_report_args
description: "Run in 'auto-update' mode (faster, less output)."
switch :force
switch :quiet
- switch :debug
switch :verbose
+ switch :debug
hide_from_man_page!
end
end | true |
Other | Homebrew | brew | 329c6c78bece4a0c8211c5c3e4495ba2a9aeb81b.json | manpages: relocate some sections
Reorder switches as force/quiet/verbose/debug, --installed before --all, and link to SPECIFYING FORMULAE from top of page. | Library/Homebrew/manpages/brew.1.md.erb | @@ -33,6 +33,9 @@ these flags should only appear after a command.
Install <formula>.
+<formula> is usually the name of the formula to install, but it has other syntaxes which
+are listed in the [SPECIFYING FORMULAE](#specifying-formulae) section.
+
### `uninstall` <formula>:
Uninstall <formula>. | true |
Other | Homebrew | brew | b567ed738ef9acfde242a0bda2860aab42c1b219.json | Remove Azure Pipelines CI. | Library/Homebrew/extend/os/mac/diagnostic.rb | @@ -72,7 +72,7 @@ def check_xcode_up_to_date
# `brew test-bot` runs `brew doctor` in the CI for the Homebrew/brew
# repository. This only needs to support whatever CI providers
# Homebrew/brew is currently using.
- return if ENV["HOMEBREW_AZURE_PIPELINES"] || ENV["HOMEBREW_GITHUB_ACTIONS"]
+ return if ENV["HOMEBREW_GITHUB_ACTIONS"]
message = <<~EOS
Your Xcode (#{MacOS::Xcode.version}) is outdated.
@@ -99,7 +99,7 @@ def check_clt_up_to_date
# `brew test-bot` runs `brew doctor` in the CI for the Homebrew/brew
# repository. This only needs to support whatever CI providers
# Homebrew/brew is currently using.
- return if ENV["HOMEBREW_AZURE_PIPELINES"] || ENV["HOMEBREW_GITHUB_ACTIONS"]
+ return if ENV["HOMEBREW_GITHUB_ACTIONS"]
<<~EOS
A newer Command Line Tools release is available. | true |
Other | Homebrew | brew | b567ed738ef9acfde242a0bda2860aab42c1b219.json | Remove Azure Pipelines CI. | azure-pipelines.yml | @@ -1,29 +0,0 @@
-jobs:
-- job: macOS
- pool:
- vmImage: macOS-10.14
- steps:
- - bash: |
- set -e
- sudo xcode-select --switch /Applications/Xcode_10.2.app/Contents/Developer
- HOMEBREW_REPOSITORY="$(brew --repo)"
- mv "$HOMEBREW_REPOSITORY/Library/Taps" "$PWD/Library"
- sudo rm -rf "$HOMEBREW_REPOSITORY"
- sudo ln -s "$PWD" "$HOMEBREW_REPOSITORY"
- brew update-reset Library/Taps/homebrew/homebrew-core
- brew test-bot
- displayName: Run brew test-bot
- env:
- HOMEBREW_GITHUB_API_TOKEN: $(github.publicApiToken)
-
-- job: Linux
- pool:
- vmImage: ubuntu-16.04
- steps:
- - bash: docker-compose -f Dockerfile.yml build sut
- displayName: Build Docker image
-
- - bash: docker-compose -f Dockerfile.yml run --rm -v $(Build.ArtifactStagingDirectory):/tmp/test-bot sut
- displayName: Run brew test-bot
- env:
- HOMEBREW_GITHUB_API_TOKEN: $(github.publicApiToken) | true |
Other | Homebrew | brew | 7ddc185b35260791e0cd21319f39f6202b7041ed.json | Fix various typos | Library/Homebrew/build.rb | @@ -197,7 +197,7 @@ def fixopt(f)
# Special case: need to recreate BuildErrors in full
# for proper analytics reporting and error messages.
- # BuildErrors are specific to build processses and not other
+ # BuildErrors are specific to build processes and not other
# children, which is why we create the necessary state here
# and not in Utils.safe_fork.
if error_hash["json_class"] == "BuildError" | true |
Other | Homebrew | brew | 7ddc185b35260791e0cd21319f39f6202b7041ed.json | Fix various typos | Library/Homebrew/cmd/missing.rb | @@ -11,7 +11,7 @@ module Homebrew
def missing_args
Homebrew::CLI::Parser.new do
usage_banner <<~EOS
- `missing` [<options>] [<formule>]
+ `missing` [<options>] [<formulae>]
Check the given <formula> for missing dependencies. If no <formula> are
given, check all installed brews. | true |
Other | Homebrew | brew | 7ddc185b35260791e0cd21319f39f6202b7041ed.json | Fix various typos | Library/Homebrew/formulary.rb | @@ -71,7 +71,7 @@ def self.resolve(name, spec: nil)
# instead have found the new formula.)
#
# Because of this, the user is referring to this specific formula,
- # not any formula targetted by the same alias, so in this context
+ # not any formula targeted by the same alias, so in this context
# the formula shouldn't be considered outdated if the alias used to
# install it has changed.
f.follow_installed_alias = false | true |
Other | Homebrew | brew | 7ddc185b35260791e0cd21319f39f6202b7041ed.json | Fix various typos | Library/Homebrew/os/mac/version.rb | @@ -42,7 +42,7 @@ def pretty_name
to_sym.to_s.split("_").map(&:capitalize).join(" ")
end
- # For OS::Mac::Version compatability
+ # For OS::Mac::Version compatibility
def requires_nehalem_cpu?
Hardware.oldest_cpu(self) == :nehalem
end | true |
Other | Homebrew | brew | 7ddc185b35260791e0cd21319f39f6202b7041ed.json | Fix various typos | Library/Homebrew/rubocops/components_order.rb | @@ -115,7 +115,7 @@ def reorder_components(corrector, node1, node2)
corrector.insert_after(node2.source_range, line_breaks + indentation + node1.source)
else
indentation = " " * (start_column(node2) - line_start_column(node2))
- # No line breaks upto version_scheme, order_idx == 8
+ # No line breaks up to version_scheme, order_idx == 8
line_breaks = (order_idx > 8) ? "\n\n" : "\n"
corrector.insert_before(node2.source_range, node1.source + line_breaks + indentation)
end | true |
Other | Homebrew | brew | 7ddc185b35260791e0cd21319f39f6202b7041ed.json | Fix various typos | Library/Homebrew/shims/super/cc | @@ -381,7 +381,7 @@ class Cmd
paths.map! { |path| prefix + path }
end
- # Unlike path_flags, do not prune non-existant directories.
+ # Unlike path_flags, do not prune non-existent directories.
# formula.lib for example does not yet exist, but should not be pruned.
def rpath_flags(prefix, paths)
paths.uniq.map { |path| prefix + path } | true |
Other | Homebrew | brew | 7ddc185b35260791e0cd21319f39f6202b7041ed.json | Fix various typos | Library/Homebrew/test/ENV_spec.rb | @@ -67,7 +67,7 @@
expect(subject["foo"]).to eq("1")
end
- it "appends to a non-existant key" do
+ it "appends to a non-existent key" do
subject.append "foo", "1"
expect(subject["foo"]).to eq("1")
end
@@ -93,7 +93,7 @@
expect(subject["foo"]).to eq("1")
end
- it "prepends to a non-existant key" do
+ it "prepends to a non-existent key" do
subject.prepend "foo", "1"
expect(subject["foo"]).to eq("1")
end | true |
Other | Homebrew | brew | 7ddc185b35260791e0cd21319f39f6202b7041ed.json | Fix various typos | Library/Homebrew/test/cask/cask_spec.rb | @@ -185,7 +185,7 @@
end
context "when it is from no known tap" do
- it "retuns the cask token" do
+ it "returns the cask token" do
file = Tempfile.new(%w[tapless-cask .rb])
begin | true |
Other | Homebrew | brew | 7ddc185b35260791e0cd21319f39f6202b7041ed.json | Fix various typos | Library/Homebrew/test/cask/cmd/edit_spec.rb | @@ -23,7 +23,7 @@
}.to raise_error(/Only one Cask can be edited at a time\./)
end
- it "raises an exception when the Cask doesnt exist" do
+ it "raises an exception when the Cask doesn't exist" do
expect {
described_class.run("notacask")
}.to raise_error(Cask::CaskUnavailableError) | true |
Other | Homebrew | brew | 7ddc185b35260791e0cd21319f39f6202b7041ed.json | Fix various typos | Library/Homebrew/test/cask/cmd/outdated_spec.rb | @@ -21,7 +21,7 @@
it_behaves_like "a command that handles invalid options"
- describe 'without --greedy it ignores the Casks with "vesion latest" or "auto_updates true"' do
+ describe 'without --greedy it ignores the Casks with "version latest" or "auto_updates true"' do
it "checks all the installed Casks when no token is provided" do
expect {
described_class.run | true |
Other | Homebrew | brew | 7ddc185b35260791e0cd21319f39f6202b7041ed.json | Fix various typos | Library/Homebrew/test/formula_validation_spec.rb | @@ -21,7 +21,7 @@ def supports_block_expectations?
end
end
- it "cant override the `brew` method" do
+ it "can't override the `brew` method" do
expect {
formula do
def brew; end | true |
Other | Homebrew | brew | 7ddc185b35260791e0cd21319f39f6202b7041ed.json | Fix various typos | Library/Homebrew/test/inreplace_spec.rb | @@ -199,7 +199,7 @@
describe "#sub!" do
let(:string) { "foo" }
- it "replaces the first occurence" do
+ it "replaces the first occurrence" do
subject.sub!("o", "e")
expect(subject).to eq("feo")
end
@@ -208,7 +208,7 @@
describe "#gsub!" do
let(:string) { "foo" }
- it "replaces the all occurences" do
+ it "replaces all occurrences" do
subject.gsub!("o", "e") # rubocop:disable Performance/StringReplacement
expect(subject).to eq("fee")
end | true |
Other | Homebrew | brew | 7ddc185b35260791e0cd21319f39f6202b7041ed.json | Fix various typos | Library/Homebrew/test/resource_spec.rb | @@ -38,7 +38,7 @@
expect(subject.download_strategy).to eq(GitDownloadStrategy)
end
- it "raises an error if the download strategy class is unkown" do
+ it "raises an error if the download strategy class is unknown" do
expect { subject.url("foo", using: Class.new) }.to raise_error(TypeError)
end
| true |
Other | Homebrew | brew | 7ddc185b35260791e0cd21319f39f6202b7041ed.json | Fix various typos | Library/Homebrew/test/tab_spec.rb | @@ -307,7 +307,7 @@
expect(subject.tabfile).to eq(f_tab_path)
end
- it "can create a Tab for a non-existant Keg" do
+ it "can create a Tab for a non-existent Keg" do
f.prefix.mkpath
expect(subject.tabfile).to eq(f_tab_path)
@@ -336,7 +336,7 @@
expect(tab.tabfile).to eq(f_tab_path)
end
- it "can create a Tab for a non-existant Formula" do
+ it "can create a Tab for a non-existent Formula" do
f.prefix.mkpath
tab = described_class.for_formula(f) | true |
Other | Homebrew | brew | 7ddc185b35260791e0cd21319f39f6202b7041ed.json | Fix various typos | Library/Homebrew/version/null.rb | @@ -28,7 +28,7 @@ def null?
true
end
- # For OS::Mac::Version compatability
+ # For OS::Mac::Version compatibility
def requires_nehalem_cpu?
false
end | true |
Other | Homebrew | brew | 7ddc185b35260791e0cd21319f39f6202b7041ed.json | Fix various typos | completions/fish/brew.fish | @@ -25,7 +25,7 @@ function __fish_brew_opts -d "Only arguments starting with a dash (options)"
string match --all -- '-*' (__fish_brew_args)
end
-# This can be used either to get the first argument or to match it against a given list of commmands
+# This can be used either to get the first argument or to match it against a given list of commands
#
# Usage examples (for `completion -n '...'`):
# * `__fish_brew_command` returns the command (first arg of brew) or exits with 1
@@ -59,7 +59,7 @@ function __fish_brew_subcommand -a cmd -d "Helps matching the second argument of
end
end
-# This can be used to match any given options agains the given list of arguments:
+# This can be used to match any given option against the given list of arguments:
# * to add condition on interdependent options
# * to ddd condition on mutually exclusive options
#
@@ -390,7 +390,7 @@ __fish_brew_complete_arg 'install upgrade' -l keep-tmp -d "Keep temp fi
__fish_brew_complete_arg 'install upgrade' -l build-bottle -d "Prepare the formula for eventual bottling during installation"
__fish_brew_complete_arg 'install upgrade' -s i -l interactive -d "Download and patch formula, then open a shell"
__fish_brew_complete_arg 'install upgrade; and __fish_brew_opt -i --interactive' -s g -l git -d "Create a Git repository for working on patches"
-# fomrula installtion options are listed after the formula name:
+# formula installation options are listed after the formula name:
__fish_brew_complete_arg 'install;
and [ (count (__fish_brew_args)) -ge 2 ];
and not string match --quiet -- "-*" (__fish_brew_args)[-1] | true |
Other | Homebrew | brew | 7ddc185b35260791e0cd21319f39f6202b7041ed.json | Fix various typos | completions/zsh/_brew | @@ -219,7 +219,7 @@ _brew_audit() {
_arguments \
'(--new-formula)--strict[run additional checks including RuboCop style checks]' \
'(--new-formula)--online[run slower checks that require a network connection]' \
- '(--online --strict)--new-formula[check if a new formula is eligable for Homebrew. Implies --strict and --online]' \
+ '(--online --strict)--new-formula[check if a new formula is eligible for Homebrew. Implies --strict and --online]' \
'--display-cop-names[include RuboCop cop name for each violation in the output]' \
'--display-filename[prefix every line of output with the name of the file or formula being audited]' \
'*:formula:__brew_formulae' | true |
Other | Homebrew | brew | e5899a6101320cb0ed10ddf0434802d752b2c78b.json | Move global methods into `Kernel` module.
Otherwise they are not defined inside of subclasses of `DelegateClass`. | Library/Homebrew/utils.rb | @@ -16,177 +16,6 @@
require "tap_constants"
require "time"
-def require?(path)
- return false if path.nil?
-
- require path
- true
-rescue LoadError => e
- # we should raise on syntax errors but not if the file doesn't exist.
- raise unless e.message.include?(path)
-end
-
-def ohai_title(title)
- title = Tty.truncate(title) if $stdout.tty? && !ARGV.verbose?
- Formatter.headline(title, color: :blue)
-end
-
-def ohai(title, *sput)
- puts ohai_title(title)
- puts sput
-end
-
-def odebug(title, *sput)
- return unless ARGV.debug?
-
- puts Formatter.headline(title, color: :magenta)
- puts sput unless sput.empty?
-end
-
-def oh1(title, options = {})
- title = Tty.truncate(title) if $stdout.tty? && !ARGV.verbose? && options.fetch(:truncate, :auto) == :auto
- puts Formatter.headline(title, color: :green)
-end
-
-# Print a warning (do this rarely)
-def opoo(message)
- $stderr.puts Formatter.warning(message, label: "Warning")
-end
-
-def onoe(message)
- $stderr.puts Formatter.error(message, label: "Error")
-end
-
-def ofail(error)
- onoe error
- Homebrew.failed = true
-end
-
-def odie(error)
- onoe error
- exit 1
-end
-
-def odeprecated(method, replacement = nil, disable: false, disable_on: nil, caller: send(:caller))
- replacement_message = if replacement
- "Use #{replacement} instead."
- else
- "There is no replacement."
- end
-
- unless disable_on.nil?
- if disable_on > Time.now
- will_be_disabled_message = " and will be disabled on #{disable_on.strftime("%Y-%m-%d")}"
- else
- disable = true
- end
- end
-
- verb = if disable
- "disabled"
- else
- "deprecated#{will_be_disabled_message}"
- end
-
- # Try to show the most relevant location in message, i.e. (if applicable):
- # - Location in a formula.
- # - Location outside of 'compat/'.
- # - Location of caller of deprecated method (if all else fails).
- backtrace = caller
-
- # Don't throw deprecations at all for cached, .brew or .metadata files.
- return if backtrace.any? do |line|
- line.include?(HOMEBREW_CACHE) ||
- line.include?("/.brew/") ||
- line.include?("/.metadata/")
- end
-
- tap_message = nil
-
- backtrace.each do |line|
- next unless match = line.match(HOMEBREW_TAP_PATH_REGEX)
-
- tap = Tap.fetch(match[:user], match[:repo])
- tap_message = +"\nPlease report this to the #{tap} tap"
- tap_message += ", or even better, submit a PR to fix it" if replacement
- tap_message << ":\n #{line.sub(/^(.*\:\d+)\:.*$/, '\1')}\n\n"
- break
- end
-
- message = +"Calling #{method} is #{verb}! #{replacement_message}"
- message << tap_message if tap_message
- message.freeze
-
- if ARGV.homebrew_developer? || disable || Homebrew.raise_deprecation_exceptions?
- exception = MethodDeprecatedError.new(message)
- exception.set_backtrace(backtrace)
- raise exception
- elsif !Homebrew.auditing?
- opoo message
- end
-end
-
-def odisabled(method, replacement = nil, options = {})
- options = { disable: true, caller: caller }.merge(options)
- odeprecated(method, replacement, options)
-end
-
-def pretty_installed(f)
- if !$stdout.tty?
- f.to_s
- elsif Emoji.enabled?
- "#{Tty.bold}#{f} #{Formatter.success("✔")}#{Tty.reset}"
- else
- Formatter.success("#{Tty.bold}#{f} (installed)#{Tty.reset}")
- end
-end
-
-def pretty_uninstalled(f)
- if !$stdout.tty?
- f.to_s
- elsif Emoji.enabled?
- "#{Tty.bold}#{f} #{Formatter.error("✘")}#{Tty.reset}"
- else
- Formatter.error("#{Tty.bold}#{f} (uninstalled)#{Tty.reset}")
- end
-end
-
-def pretty_duration(s)
- s = s.to_i
- res = +""
-
- if s > 59
- m = s / 60
- s %= 60
- res = +"#{m} #{"minute".pluralize(m)}"
- return res.freeze if s.zero?
-
- res << " "
- end
-
- res << "#{s} #{"second".pluralize(s)}"
- res.freeze
-end
-
-def interactive_shell(f = nil)
- unless f.nil?
- ENV["HOMEBREW_DEBUG_PREFIX"] = f.prefix
- ENV["HOMEBREW_DEBUG_INSTALL"] = f.full_name
- end
-
- if ENV["SHELL"].include?("zsh") && ENV["HOME"].start_with?(HOMEBREW_TEMP.resolved_path.to_s)
- FileUtils.mkdir_p ENV["HOME"]
- FileUtils.touch "#{ENV["HOME"]}/.zshrc"
- end
-
- Process.wait fork { exec ENV["SHELL"] }
-
- return if $CHILD_STATUS.success?
- raise "Aborted due to non-zero exit status (#{$CHILD_STATUS.exitstatus})" if $CHILD_STATUS.exited?
-
- raise $CHILD_STATUS.inspect
-end
-
module Homebrew
module_function
@@ -245,264 +74,437 @@ def inject_dump_stats!(the_module, pattern)
# rubocop:enable Style/GlobalVars
end
-def with_homebrew_path
- with_env(PATH: PATH.new(ENV["HOMEBREW_PATH"])) do
- yield
+module Kernel
+ def require?(path)
+ return false if path.nil?
+
+ require path
+ true
+ rescue LoadError => e
+ # we should raise on syntax errors but not if the file doesn't exist.
+ raise unless e.message.include?(path)
end
-end
-def with_custom_locale(locale)
- with_env(LC_ALL: locale) do
- yield
+ def ohai_title(title)
+ title = Tty.truncate(title) if $stdout.tty? && !ARGV.verbose?
+ Formatter.headline(title, color: :blue)
end
-end
-# Kernel.system but with exceptions
-def safe_system(cmd, *args, **options)
- return if Homebrew.system(cmd, *args, **options)
+ def ohai(title, *sput)
+ puts ohai_title(title)
+ puts sput
+ end
- raise ErrorDuringExecution.new([cmd, *args], status: $CHILD_STATUS)
-end
+ def odebug(title, *sput)
+ return unless ARGV.debug?
-# Prints no output
-def quiet_system(cmd, *args)
- Homebrew._system(cmd, *args) do
- # Redirect output streams to `/dev/null` instead of closing as some programs
- # will fail to execute if they can't write to an open stream.
- $stdout.reopen("/dev/null")
- $stderr.reopen("/dev/null")
+ puts Formatter.headline(title, color: :magenta)
+ puts sput unless sput.empty?
end
-end
-def which(cmd, path = ENV["PATH"])
- PATH.new(path).each do |p|
- begin
- pcmd = File.expand_path(cmd, p)
- rescue ArgumentError
- # File.expand_path will raise an ArgumentError if the path is malformed.
- # See https://github.com/Homebrew/legacy-homebrew/issues/32789
- next
- end
- return Pathname.new(pcmd) if File.file?(pcmd) && File.executable?(pcmd)
+ def oh1(title, options = {})
+ title = Tty.truncate(title) if $stdout.tty? && !ARGV.verbose? && options.fetch(:truncate, :auto) == :auto
+ puts Formatter.headline(title, color: :green)
end
- nil
-end
-def which_all(cmd, path = ENV["PATH"])
- PATH.new(path).map do |p|
- begin
- pcmd = File.expand_path(cmd, p)
- rescue ArgumentError
- # File.expand_path will raise an ArgumentError if the path is malformed.
- # See https://github.com/Homebrew/legacy-homebrew/issues/32789
- next
+ # Print a warning (do this rarely)
+ def opoo(message)
+ $stderr.puts Formatter.warning(message, label: "Warning")
+ end
+
+ def onoe(message)
+ $stderr.puts Formatter.error(message, label: "Error")
+ end
+
+ def ofail(error)
+ onoe error
+ Homebrew.failed = true
+ end
+
+ def odie(error)
+ onoe error
+ exit 1
+ end
+
+ def odeprecated(method, replacement = nil, disable: false, disable_on: nil, caller: send(:caller))
+ replacement_message = if replacement
+ "Use #{replacement} instead."
+ else
+ "There is no replacement."
+ end
+
+ unless disable_on.nil?
+ if disable_on > Time.now
+ will_be_disabled_message = " and will be disabled on #{disable_on.strftime("%Y-%m-%d")}"
+ else
+ disable = true
+ end
+ end
+
+ verb = if disable
+ "disabled"
+ else
+ "deprecated#{will_be_disabled_message}"
+ end
+
+ # Try to show the most relevant location in message, i.e. (if applicable):
+ # - Location in a formula.
+ # - Location outside of 'compat/'.
+ # - Location of caller of deprecated method (if all else fails).
+ backtrace = caller
+
+ # Don't throw deprecations at all for cached, .brew or .metadata files.
+ return if backtrace.any? do |line|
+ line.include?(HOMEBREW_CACHE) ||
+ line.include?("/.brew/") ||
+ line.include?("/.metadata/")
+ end
+
+ tap_message = nil
+
+ backtrace.each do |line|
+ next unless match = line.match(HOMEBREW_TAP_PATH_REGEX)
+
+ tap = Tap.fetch(match[:user], match[:repo])
+ tap_message = +"\nPlease report this to the #{tap} tap"
+ tap_message += ", or even better, submit a PR to fix it" if replacement
+ tap_message << ":\n #{line.sub(/^(.*\:\d+)\:.*$/, '\1')}\n\n"
+ break
end
- Pathname.new(pcmd) if File.file?(pcmd) && File.executable?(pcmd)
- end.compact.uniq
-end
-def which_editor
- editor = ENV.values_at("HOMEBREW_EDITOR", "HOMEBREW_VISUAL")
- .compact
- .reject(&:empty?)
- .first
- return editor if editor
+ message = +"Calling #{method} is #{verb}! #{replacement_message}"
+ message << tap_message if tap_message
+ message.freeze
- # Find Atom, Sublime Text, Textmate, BBEdit / TextWrangler, or vim
- editor = %w[atom subl mate edit vim].find do |candidate|
- candidate if which(candidate, ENV["HOMEBREW_PATH"])
+ if ARGV.homebrew_developer? || disable || Homebrew.raise_deprecation_exceptions?
+ exception = MethodDeprecatedError.new(message)
+ exception.set_backtrace(backtrace)
+ raise exception
+ elsif !Homebrew.auditing?
+ opoo message
+ end
end
- editor ||= "vim"
- opoo <<~EOS
- Using #{editor} because no editor was set in the environment.
- This may change in the future, so we recommend setting EDITOR,
- or HOMEBREW_EDITOR to your preferred text editor.
- EOS
+ def odisabled(method, replacement = nil, options = {})
+ options = { disable: true, caller: caller }.merge(options)
+ odeprecated(method, replacement, options)
+ end
- editor
-end
+ def pretty_installed(f)
+ if !$stdout.tty?
+ f.to_s
+ elsif Emoji.enabled?
+ "#{Tty.bold}#{f} #{Formatter.success("✔")}#{Tty.reset}"
+ else
+ Formatter.success("#{Tty.bold}#{f} (installed)#{Tty.reset}")
+ end
+ end
-def exec_editor(*args)
- puts "Editing #{args.join "\n"}"
- with_homebrew_path { safe_system(*which_editor.shellsplit, *args) }
-end
+ def pretty_uninstalled(f)
+ if !$stdout.tty?
+ f.to_s
+ elsif Emoji.enabled?
+ "#{Tty.bold}#{f} #{Formatter.error("✘")}#{Tty.reset}"
+ else
+ Formatter.error("#{Tty.bold}#{f} (uninstalled)#{Tty.reset}")
+ end
+ end
-def exec_browser(*args)
- browser = ENV["HOMEBREW_BROWSER"]
- browser ||= OS::PATH_OPEN if defined?(OS::PATH_OPEN)
- return unless browser
+ def pretty_duration(s)
+ s = s.to_i
+ res = +""
- ENV["DISPLAY"] = ENV["HOMEBREW_DISPLAY"]
+ if s > 59
+ m = s / 60
+ s %= 60
+ res = +"#{m} #{"minute".pluralize(m)}"
+ return res.freeze if s.zero?
- safe_system(browser, *args)
-end
+ res << " "
+ end
-# GZips the given paths, and returns the gzipped paths
-def gzip(*paths)
- paths.map do |path|
- safe_system "gzip", path
- Pathname.new("#{path}.gz")
+ res << "#{s} #{"second".pluralize(s)}"
+ res.freeze
end
-end
-# Returns array of architectures that the given command or library is built for.
-def archs_for_command(cmd)
- cmd = which(cmd) unless Pathname.new(cmd).absolute?
- Pathname.new(cmd).archs
-end
+ def interactive_shell(f = nil)
+ unless f.nil?
+ ENV["HOMEBREW_DEBUG_PREFIX"] = f.prefix
+ ENV["HOMEBREW_DEBUG_INSTALL"] = f.full_name
+ end
+
+ if ENV["SHELL"].include?("zsh") && ENV["HOME"].start_with?(HOMEBREW_TEMP.resolved_path.to_s)
+ FileUtils.mkdir_p ENV["HOME"]
+ FileUtils.touch "#{ENV["HOME"]}/.zshrc"
+ end
+
+ Process.wait fork { exec ENV["SHELL"] }
-def ignore_interrupts(opt = nil)
- std_trap = trap("INT") do
- puts "One sec, just cleaning up" unless opt == :quietly
+ return if $CHILD_STATUS.success?
+ raise "Aborted due to non-zero exit status (#{$CHILD_STATUS.exitstatus})" if $CHILD_STATUS.exited?
+
+ raise $CHILD_STATUS.inspect
end
- yield
-ensure
- trap("INT", std_trap)
-end
-def capture_stderr
- old = $stderr
- $stderr = StringIO.new
- yield
- $stderr.string
-ensure
- $stderr = old
-end
+ def with_homebrew_path
+ with_env(PATH: PATH.new(ENV["HOMEBREW_PATH"])) do
+ yield
+ end
+ end
-def nostdout
- if ARGV.verbose?
- yield
- else
- begin
- out = $stdout.dup
- $stdout.reopen("/dev/null")
+ def with_custom_locale(locale)
+ with_env(LC_ALL: locale) do
yield
- ensure
- $stdout.reopen(out)
- out.close
end
end
-end
-def paths
- @paths ||= PATH.new(ENV["HOMEBREW_PATH"]).map do |p|
- begin
- File.expand_path(p).chomp("/")
- rescue ArgumentError
- onoe "The following PATH component is invalid: #{p}"
+ # Kernel.system but with exceptions
+ def safe_system(cmd, *args, **options)
+ return if Homebrew.system(cmd, *args, **options)
+
+ raise ErrorDuringExecution.new([cmd, *args], status: $CHILD_STATUS)
+ end
+
+ # Prints no output
+ def quiet_system(cmd, *args)
+ Homebrew._system(cmd, *args) do
+ # Redirect output streams to `/dev/null` instead of closing as some programs
+ # will fail to execute if they can't write to an open stream.
+ $stdout.reopen("/dev/null")
+ $stderr.reopen("/dev/null")
end
- end.uniq.compact
-end
+ end
-def disk_usage_readable(size_in_bytes)
- if size_in_bytes >= 1_073_741_824
- size = size_in_bytes.to_f / 1_073_741_824
- unit = "GB"
- elsif size_in_bytes >= 1_048_576
- size = size_in_bytes.to_f / 1_048_576
- unit = "MB"
- elsif size_in_bytes >= 1_024
- size = size_in_bytes.to_f / 1_024
- unit = "KB"
- else
- size = size_in_bytes
- unit = "B"
- end
-
- # avoid trailing zero after decimal point
- if ((size * 10).to_i % 10).zero?
- "#{size.to_i}#{unit}"
- else
- "#{format("%.1f", size)}#{unit}"
+ def which(cmd, path = ENV["PATH"])
+ PATH.new(path).each do |p|
+ begin
+ pcmd = File.expand_path(cmd, p)
+ rescue ArgumentError
+ # File.expand_path will raise an ArgumentError if the path is malformed.
+ # See https://github.com/Homebrew/legacy-homebrew/issues/32789
+ next
+ end
+ return Pathname.new(pcmd) if File.file?(pcmd) && File.executable?(pcmd)
+ end
+ nil
end
-end
-def number_readable(number)
- numstr = number.to_i.to_s
- (numstr.size - 3).step(1, -3) { |i| numstr.insert(i, ",") }
- numstr
-end
+ def which_all(cmd, path = ENV["PATH"])
+ PATH.new(path).map do |p|
+ begin
+ pcmd = File.expand_path(cmd, p)
+ rescue ArgumentError
+ # File.expand_path will raise an ArgumentError if the path is malformed.
+ # See https://github.com/Homebrew/legacy-homebrew/issues/32789
+ next
+ end
+ Pathname.new(pcmd) if File.file?(pcmd) && File.executable?(pcmd)
+ end.compact.uniq
+ end
-# Truncates a text string to fit within a byte size constraint,
-# preserving character encoding validity. The returned string will
-# be not much longer than the specified max_bytes, though the exact
-# shortfall or overrun may vary.
-def truncate_text_to_approximate_size(s, max_bytes, options = {})
- front_weight = options.fetch(:front_weight, 0.5)
- raise "opts[:front_weight] must be between 0.0 and 1.0" if front_weight < 0.0 || front_weight > 1.0
- return s if s.bytesize <= max_bytes
-
- glue = "\n[...snip...]\n"
- max_bytes_in = [max_bytes - glue.bytesize, 1].max
- bytes = s.dup.force_encoding("BINARY")
- glue_bytes = glue.encode("BINARY")
- n_front_bytes = (max_bytes_in * front_weight).floor
- n_back_bytes = max_bytes_in - n_front_bytes
- if n_front_bytes.zero?
- front = bytes[1..0]
- back = bytes[-max_bytes_in..-1]
- elsif n_back_bytes.zero?
- front = bytes[0..(max_bytes_in - 1)]
- back = bytes[1..0]
- else
- front = bytes[0..(n_front_bytes - 1)]
- back = bytes[-n_back_bytes..-1]
- end
- out = front + glue_bytes + back
- out.force_encoding("UTF-8")
- out.encode!("UTF-16", invalid: :replace)
- out.encode!("UTF-8")
- out
-end
+ def which_editor
+ editor = ENV.values_at("HOMEBREW_EDITOR", "HOMEBREW_VISUAL")
+ .compact
+ .reject(&:empty?)
+ .first
+ return editor if editor
-# Calls the given block with the passed environment variables
-# added to ENV, then restores ENV afterwards.
-# Example:
-# <pre>with_env(PATH: "/bin") do
-# system "echo $PATH"
-# end</pre>
-#
-# Note that this method is *not* thread-safe - other threads
-# which happen to be scheduled during the block will also
-# see these environment variables.
-def with_env(hash)
- old_values = {}
- begin
- hash.each do |key, value|
- key = key.to_s
- old_values[key] = ENV.delete(key)
- ENV[key] = value
+ # Find Atom, Sublime Text, Textmate, BBEdit / TextWrangler, or vim
+ editor = %w[atom subl mate edit vim].find do |candidate|
+ candidate if which(candidate, ENV["HOMEBREW_PATH"])
end
+ editor ||= "vim"
+
+ opoo <<~EOS
+ Using #{editor} because no editor was set in the environment.
+ This may change in the future, so we recommend setting EDITOR,
+ or HOMEBREW_EDITOR to your preferred text editor.
+ EOS
+
+ editor
+ end
+
+ def exec_editor(*args)
+ puts "Editing #{args.join "\n"}"
+ with_homebrew_path { safe_system(*which_editor.shellsplit, *args) }
+ end
+
+ def exec_browser(*args)
+ browser = ENV["HOMEBREW_BROWSER"]
+ browser ||= OS::PATH_OPEN if defined?(OS::PATH_OPEN)
+ return unless browser
+
+ ENV["DISPLAY"] = ENV["HOMEBREW_DISPLAY"]
- yield if block_given?
+ safe_system(browser, *args)
+ end
+
+ # GZips the given paths, and returns the gzipped paths
+ def gzip(*paths)
+ paths.map do |path|
+ safe_system "gzip", path
+ Pathname.new("#{path}.gz")
+ end
+ end
+
+ # Returns array of architectures that the given command or library is built for.
+ def archs_for_command(cmd)
+ cmd = which(cmd) unless Pathname.new(cmd).absolute?
+ Pathname.new(cmd).archs
+ end
+
+ def ignore_interrupts(opt = nil)
+ std_trap = trap("INT") do
+ puts "One sec, just cleaning up" unless opt == :quietly
+ end
+ yield
ensure
- ENV.update(old_values)
+ trap("INT", std_trap)
end
-end
-def shell_profile
- Utils::Shell.profile
-end
+ def capture_stderr
+ old = $stderr
+ $stderr = StringIO.new
+ yield
+ $stderr.string
+ ensure
+ $stderr = old
+ end
-def tap_and_name_comparison
- proc do |a, b|
- if a.include?("/") && !b.include?("/")
- 1
- elsif !a.include?("/") && b.include?("/")
- -1
+ def nostdout
+ if ARGV.verbose?
+ yield
else
- a <=> b
+ begin
+ out = $stdout.dup
+ $stdout.reopen("/dev/null")
+ yield
+ ensure
+ $stdout.reopen(out)
+ out.close
+ end
end
end
-end
-def command_help_lines(path)
- path.read.lines.grep(/^#:/).map { |line| line.slice(2..-1) }
-end
+ def paths
+ @paths ||= PATH.new(ENV["HOMEBREW_PATH"]).map do |p|
+ begin
+ File.expand_path(p).chomp("/")
+ rescue ArgumentError
+ onoe "The following PATH component is invalid: #{p}"
+ end
+ end.uniq.compact
+ end
-def redact_secrets(input, secrets)
- secrets.compact
- .reduce(input) { |str, secret| str.gsub secret, "******" }
- .freeze
+ def disk_usage_readable(size_in_bytes)
+ if size_in_bytes >= 1_073_741_824
+ size = size_in_bytes.to_f / 1_073_741_824
+ unit = "GB"
+ elsif size_in_bytes >= 1_048_576
+ size = size_in_bytes.to_f / 1_048_576
+ unit = "MB"
+ elsif size_in_bytes >= 1_024
+ size = size_in_bytes.to_f / 1_024
+ unit = "KB"
+ else
+ size = size_in_bytes
+ unit = "B"
+ end
+
+ # avoid trailing zero after decimal point
+ if ((size * 10).to_i % 10).zero?
+ "#{size.to_i}#{unit}"
+ else
+ "#{format("%.1f", size)}#{unit}"
+ end
+ end
+
+ def number_readable(number)
+ numstr = number.to_i.to_s
+ (numstr.size - 3).step(1, -3) { |i| numstr.insert(i, ",") }
+ numstr
+ end
+
+ # Truncates a text string to fit within a byte size constraint,
+ # preserving character encoding validity. The returned string will
+ # be not much longer than the specified max_bytes, though the exact
+ # shortfall or overrun may vary.
+ def truncate_text_to_approximate_size(s, max_bytes, options = {})
+ front_weight = options.fetch(:front_weight, 0.5)
+ raise "opts[:front_weight] must be between 0.0 and 1.0" if front_weight < 0.0 || front_weight > 1.0
+ return s if s.bytesize <= max_bytes
+
+ glue = "\n[...snip...]\n"
+ max_bytes_in = [max_bytes - glue.bytesize, 1].max
+ bytes = s.dup.force_encoding("BINARY")
+ glue_bytes = glue.encode("BINARY")
+ n_front_bytes = (max_bytes_in * front_weight).floor
+ n_back_bytes = max_bytes_in - n_front_bytes
+ if n_front_bytes.zero?
+ front = bytes[1..0]
+ back = bytes[-max_bytes_in..-1]
+ elsif n_back_bytes.zero?
+ front = bytes[0..(max_bytes_in - 1)]
+ back = bytes[1..0]
+ else
+ front = bytes[0..(n_front_bytes - 1)]
+ back = bytes[-n_back_bytes..-1]
+ end
+ out = front + glue_bytes + back
+ out.force_encoding("UTF-8")
+ out.encode!("UTF-16", invalid: :replace)
+ out.encode!("UTF-8")
+ out
+ end
+
+ # Calls the given block with the passed environment variables
+ # added to ENV, then restores ENV afterwards.
+ # Example:
+ # <pre>with_env(PATH: "/bin") do
+ # system "echo $PATH"
+ # end</pre>
+ #
+ # Note that this method is *not* thread-safe - other threads
+ # which happen to be scheduled during the block will also
+ # see these environment variables.
+ def with_env(hash)
+ old_values = {}
+ begin
+ hash.each do |key, value|
+ key = key.to_s
+ old_values[key] = ENV.delete(key)
+ ENV[key] = value
+ end
+
+ yield if block_given?
+ ensure
+ ENV.update(old_values)
+ end
+ end
+
+ def shell_profile
+ Utils::Shell.profile
+ end
+
+ def tap_and_name_comparison
+ proc do |a, b|
+ if a.include?("/") && !b.include?("/")
+ 1
+ elsif !a.include?("/") && b.include?("/")
+ -1
+ else
+ a <=> b
+ end
+ end
+ end
+
+ def command_help_lines(path)
+ path.read.lines.grep(/^#:/).map { |line| line.slice(2..-1) }
+ end
+
+ def redact_secrets(input, secrets)
+ secrets.compact
+ .reduce(input) { |str, secret| str.gsub secret, "******" }
+ .freeze
+ end
end | false |
Other | Homebrew | brew | 3a6a75ac0e5af4c9069fce67d260662e6784eb70.json | gnome_devel_whitelist: add gtk-doc 1.31
Necessary for https://github.com/Homebrew/homebrew-core/pull/42851 | Library/Homebrew/dev-cmd/audit.rb | @@ -692,6 +692,7 @@ def audit_specs
libart 2.3.21
pygtkglext 1.1.0
gtk-mac-integration 2.1.3
+ gtk-doc 1.31
].each_slice(2).to_a.map do |formula, version|
[formula, version.split(".")[0..1].join(".")]
end | false |
Other | Homebrew | brew | 40c3184f82d15e0a1cfb9d40c084ad9f50ab09b5.json | gnome_devel_whitelist: add gtk-mac-integration 2.1.3
This fixes the error produced by `brew audit gtk-mac-integration --online`:
Error: 1 problem in 1 formula detected
gtk-mac-integration:
* 2.1.3 is a development release
This problem is currently blocking https://github.com/Homebrew/homebrew-core/pull/42536 | Library/Homebrew/dev-cmd/audit.rb | @@ -691,6 +691,7 @@ def audit_specs
gnome_devel_whitelist = %w[
libart 2.3.21
pygtkglext 1.1.0
+ gtk-mac-integration 2.1.3
].each_slice(2).to_a.map do |formula, version|
[formula, version.split(".")[0..1].join(".")]
end | false |
Other | Homebrew | brew | 7f6ef77d0e12b898a366dd907e4c4f3434fcb9a6.json | Address PR comments: remove test and use return ... if | Library/Homebrew/cask/cmd/upgrade.rb | @@ -42,16 +42,14 @@ def run
.map { |(old_cask, new_cask)| "#{new_cask.full_name} #{old_cask.version} -> #{new_cask.version}" }
.join(", ")
- if dry_run?
- puts "Dry run: did not upgrade anything."
- else
- upgradable_casks.each do |(old_cask, new_cask)|
- begin
- upgrade_cask(old_cask, new_cask)
- rescue CaskError => e
- caught_exceptions << e
- next
- end
+ return puts "Dry run: did not upgrade anything." if dry_run?
+
+ upgradable_casks.each do |(old_cask, new_cask)|
+ begin
+ upgrade_cask(old_cask, new_cask)
+ rescue CaskError => e
+ caught_exceptions << e
+ next
end
end
| true |
Other | Homebrew | brew | 7f6ef77d0e12b898a366dd907e4c4f3434fcb9a6.json | Address PR comments: remove test and use return ... if | Library/Homebrew/cmd/upgrade.rb | @@ -106,15 +106,13 @@ def upgrade
puts formulae_upgrades.join(", ")
end
- if args.dry_run?
- puts "Dry run: did not upgrade anything."
- else
- upgrade_formulae(formulae_to_install)
+ return puts "Dry run: did not upgrade anything." if args.dry_run?
- check_dependents(formulae_to_install)
+ upgrade_formulae(formulae_to_install)
- Homebrew.messages.display_messages
- end
+ check_dependents(formulae_to_install)
+
+ Homebrew.messages.display_messages
end
def upgrade_formulae(formulae_to_install) | true |
Other | Homebrew | brew | 7f6ef77d0e12b898a366dd907e4c4f3434fcb9a6.json | Address PR comments: remove test and use return ... if | Library/Homebrew/test/cmd/upgrade_spec.rb | @@ -16,17 +16,4 @@
expect(HOMEBREW_CELLAR/"testball/0.1").to be_a_directory
expect(HOMEBREW_CELLAR/"testball/0.0.1").not_to exist
end
-
- it "can do a dry run upgrade" do
- setup_test_formula "testball"
- (HOMEBREW_CELLAR/"testball/0.0.1/foo").mkpath
-
- expect { brew "upgrade", "--dry-run" }
- .to output(/Dry run: did not upgrade anything/).to_stdout
- .and not_to_output.to_stderr
- .and be_a_success
-
- expect(HOMEBREW_CELLAR/"testball/0.1").not_to exist
- expect(HOMEBREW_CELLAR/"testball/0.0.1").to be_a_directory
- end
end | true |
Other | Homebrew | brew | ac0ff9ae46dc47790a3c0d16c2c85b11bd08383d.json | Update md and run `brew man`. | Library/Homebrew/manpages/brew-cask.1.md | @@ -97,13 +97,16 @@ graphical user interface.
Uninstall the given Cask. With `--force`, uninstall even if the Cask
does not appear to be present.
- * `upgrade` [--force] [--greedy] <token> [ <token> ... ]:
+ * `upgrade` [--force] [--greedy] [--dry-run] <token> [ <token> ... ]:
Without token arguments, upgrade all the installed Casks that have newer
versions available in the tap; otherwise update the tokens given
in the command line.
If `--greedy` is given then also upgrade the Casks having `auto_updates true`
or `version :latest`.
+ If `--dry-run` is given, show what would be upgraded, but do not actually
+ upgrade anything.
+
* `zap` [--force] <token> [ <token> ... ]:
Unconditionally remove _all_ files associated with the given Cask.
With `--force`, zap even if the Cask does not appear to be currently installed. | true |
Other | Homebrew | brew | ac0ff9ae46dc47790a3c0d16c2c85b11bd08383d.json | Update md and run `brew man`. | manpages/brew-cask.1 | @@ -1,7 +1,7 @@
.\" generated with Ronn/v0.7.3
.\" http://github.com/rtomayko/ronn/tree/0.7.3
.
-.TH "BREW\-CASK" "1" "May 2019" "Homebrew" "brew-cask"
+.TH "BREW\-CASK" "1" "July 2019" "Homebrew" "brew-cask"
.
.SH "NAME"
\fBbrew\-cask\fR \- a friendly binary installer for macOS
@@ -103,6 +103,9 @@ Uninstall the given Cask\. With \fB\-\-force\fR, uninstall even if the Cask does
\fBupgrade\fR [\-\-force] [\-\-greedy] [\-\-dry\-run] \fItoken\fR [ \fItoken\fR \.\.\. ]
Without token arguments, upgrade all the installed Casks that have newer versions available in the tap; otherwise update the tokens given in the command line\. If \fB\-\-greedy\fR is given then also upgrade the Casks having \fBauto_updates true\fR or \fBversion :latest\fR\.
.
+.IP
+If \fB\-\-dry\-run\fR is given, show what would be upgraded, but do not actually upgrade anything\.
+.
.TP
\fBzap\fR [\-\-force] \fItoken\fR [ \fItoken\fR \.\.\. ]
Unconditionally remove \fIall\fR files associated with the given Cask\. With \fB\-\-force\fR, zap even if the Cask does not appear to be currently installed\. | true |
Other | Homebrew | brew | ac0ff9ae46dc47790a3c0d16c2c85b11bd08383d.json | Update md and run `brew man`. | manpages/brew.1 | @@ -1,7 +1,7 @@
.\" generated with Ronn/v0.7.3
.\" http://github.com/rtomayko/ronn/tree/0.7.3
.
-.TH "BREW" "1" "May 2019" "Homebrew" "brew"
+.TH "BREW" "1" "July 2019" "Homebrew" "brew"
.
.SH "NAME"
\fBbrew\fR \- The missing package manager for macOS | true |
Other | Homebrew | brew | 97cbf43a3dc8db337f6dfd703b9e5055900a4f89.json | python_virtualenv_constants: upgrade virtualenv to 16.7.2 | Library/Homebrew/language/python_virtualenv_constants.rb | @@ -1,8 +1,8 @@
# frozen_string_literal: true
PYTHON_VIRTUALENV_URL =
- "https://files.pythonhosted.org/packages/fc/e4" \
- "/f0acb4e82acd60f843308112421a41ea70c06bbce51d13fa00736d09a6ae" \
- "/virtualenv-16.7.1.tar.gz"
+ "https://files.pythonhosted.org/packages/a9/8a" \
+ "/580c7176f01540615c2eb3f3ab5462613b4beac4aa63410be89ecc7b7472" \
+ "/virtualenv-16.7.2.tar.gz"
PYTHON_VIRTUALENV_SHA256 =
- "d0158c9784570aab78cbb1e4dc59938de128d38e20e5271d9997ada4b417012c"
+ "909fe0d3f7c9151b2df0a2cb53e55bdb7b0d61469353ff7a49fd47b0f0ab9285" | false |
Other | Homebrew | brew | da20f63da1e69538de9283dd8e2b64a61d59caa0.json | python_virtualenv_constants: upgrade virtualenv to 16.7.1 | Library/Homebrew/language/python_virtualenv_constants.rb | @@ -1,8 +1,8 @@
# frozen_string_literal: true
PYTHON_VIRTUALENV_URL =
- "https://files.pythonhosted.org/packages/97/f4" \
- "/64c1853c3b35c1cfa57f3485b49c8c684f9dcaba4e24c56717b83fc66e90" \
- "/virtualenv-16.6.2.tar.gz"
+ "https://files.pythonhosted.org/packages/fc/e4" \
+ "/f0acb4e82acd60f843308112421a41ea70c06bbce51d13fa00736d09a6ae" \
+ "/virtualenv-16.7.1.tar.gz"
PYTHON_VIRTUALENV_SHA256 =
- "861bbce3a418110346c70f5c7a696fdcf23a261424e1d28aa4f9362fc2ccbc19"
+ "d0158c9784570aab78cbb1e4dc59938de128d38e20e5271d9997ada4b417012c" | false |
Other | Homebrew | brew | 739c06229dc04861d225f19480b8169e965b9727.json | curl/curl_output: allow redacting secrets in the log
Add a new argument `secrets` to specify secret tokens, so we can redact them in the log. | Library/Homebrew/utils/curl.rb | @@ -42,13 +42,14 @@ def curl_args(*extra_args, show_output: false, user_agent: :default)
args + extra_args
end
-def curl(*args)
+def curl(*args, secrets: [], **options)
# SSL_CERT_FILE can be incorrectly set by users or portable-ruby and screw
# with SSL downloads so unset it here.
system_command! curl_executable,
- args: curl_args(*args),
+ args: curl_args(*args, **options),
print_stdout: true,
- env: { "SSL_CERT_FILE" => nil }
+ env: { "SSL_CERT_FILE" => nil },
+ secrets: secrets
end
def curl_download(*args, to: nil, **options)
@@ -77,10 +78,11 @@ def curl_download(*args, to: nil, **options)
curl("--location", "--remote-time", "--continue-at", continue_at.to_s, "--output", destination, *args, **options)
end
-def curl_output(*args, **options)
- system_command(curl_executable,
+def curl_output(*args, secrets: [], **options)
+ system_command curl_executable,
args: curl_args(*args, show_output: true, **options),
- print_stderr: false)
+ print_stderr: false,
+ secrets: secrets
end
def curl_check_http_content(url, user_agents: [:default], check_content: false, strict: false) | false |
Other | Homebrew | brew | 66697d429046550904adfa3ac8e689b37c964b6a.json | ENV: add sensitive_environment function
ENV#sensitive_environment is used to list all sensitive environments.
Also refactor the code on determining whether an environment is sensitive. | Library/Homebrew/extend/ENV.rb | @@ -29,12 +29,16 @@ def with_build_environment
replace(old_env)
end
- def clear_sensitive_environment!
- each_key do |key|
- next unless /(cookie|key|token|password)/i =~ key
+ def sensitive?(key)
+ /(cookie|key|token|password)/i =~ key
+ end
- delete key
- end
+ def sensitive_environment
+ select { |key, _| sensitive?(key) }
+ end
+
+ def clear_sensitive_environment!
+ each_key { |key| delete key if sensitive?(key) }
end
end
| true |
Other | Homebrew | brew | 66697d429046550904adfa3ac8e689b37c964b6a.json | ENV: add sensitive_environment function
ENV#sensitive_environment is used to list all sensitive environments.
Also refactor the code on determining whether an environment is sensitive. | Library/Homebrew/system_config.rb | @@ -4,6 +4,7 @@
require "software_spec"
require "rexml/document"
require "development_tools"
+require "extend/ENV"
class SystemConfig
class << self
@@ -173,7 +174,7 @@ def dump_verbose_config(f = $stdout)
next if boring_keys.include?(key)
next if defaults_hash[key.to_sym]
- value = "set" if key =~ /(cookie|key|token|password)/i
+ value = "set" if ENV.sensitive?(key)
f.puts "#{key}: #{value}"
end
end | true |
Other | Homebrew | brew | 66697d429046550904adfa3ac8e689b37c964b6a.json | ENV: add sensitive_environment function
ENV#sensitive_environment is used to list all sensitive environments.
Also refactor the code on determining whether an environment is sensitive. | Library/Homebrew/test/ENV_spec.rb | @@ -143,6 +143,13 @@
expect(subject["MAKEFLAGS"]).to eq("-j4")
end
+ describe "#sensitive_environment" do
+ it "list sensitive environment" do
+ subject["SECRET_TOKEN"] = "password"
+ expect(subject.sensitive_environment).to include("SECRET_TOKEN")
+ end
+ end
+
describe "#clear_sensitive_environment!" do
it "removes sensitive environment variables" do
subject["SECRET_TOKEN"] = "password" | true |
Other | Homebrew | brew | 9232ca4508184505f140b3810823872299b480df.json | system_command: allow redacting secrets in the log
Add a new argument `secrets` to specify secret tokens, so we can redact them in the log. | Library/Homebrew/exceptions.rb | @@ -1,6 +1,7 @@
# frozen_string_literal: true
require "shellwords"
+require "utils"
class UsageError < RuntimeError
attr_reader :reason
@@ -520,7 +521,7 @@ class ErrorDuringExecution < RuntimeError
attr_reader :status
attr_reader :output
- def initialize(cmd, status:, output: nil)
+ def initialize(cmd, status:, output: nil, secrets: [])
@cmd = cmd
@status = status
@output = output
@@ -531,7 +532,8 @@ def initialize(cmd, status:, output: nil)
status
end
- s = +"Failure while executing; `#{cmd.shelljoin.gsub(/\\=/, "=")}` exited with #{exitstatus}."
+ redacted_cmd = redact_secrets(cmd.shelljoin.gsub('\=', "="), secrets)
+ s = +"Failure while executing; `#{redacted_cmd}` exited with #{exitstatus}."
unless [*output].empty?
format_output_line = lambda do |type_line| | true |
Other | Homebrew | brew | 9232ca4508184505f140b3810823872299b480df.json | system_command: allow redacting secrets in the log
Add a new argument `secrets` to specify secret tokens, so we can redact them in the log. | Library/Homebrew/system_command.rb | @@ -34,7 +34,7 @@ def self.run!(command, **options)
end
def run!
- puts command.shelljoin.gsub(/\\=/, "=") if verbose? || ARGV.debug?
+ puts redact_secrets(command.shelljoin.gsub('\=', "="), @secrets) if verbose? || ARGV.debug?
@output = []
@@ -54,7 +54,7 @@ def run!
end
def initialize(executable, args: [], sudo: false, env: {}, input: [], must_succeed: false,
- print_stdout: false, print_stderr: true, verbose: false, **options)
+ print_stdout: false, print_stderr: true, verbose: false, secrets: [], **options)
@executable = executable
@args = args
@@ -63,6 +63,7 @@ def initialize(executable, args: [], sudo: false, env: {}, input: [], must_succe
@print_stdout = print_stdout
@print_stderr = print_stderr
@verbose = verbose
+ @secrets = Array(secrets)
@must_succeed = must_succeed
options.assert_valid_keys!(:chdir)
@options = options
@@ -106,9 +107,7 @@ def sudo_prefix
def assert_success
return if @status.success?
- raise ErrorDuringExecution.new(command,
- status: @status,
- output: @output)
+ raise ErrorDuringExecution.new(command, status: @status, output: @output, secrets: @secrets)
end
def expanded_args | true |
Other | Homebrew | brew | 9232ca4508184505f140b3810823872299b480df.json | system_command: allow redacting secrets in the log
Add a new argument `secrets` to specify secret tokens, so we can redact them in the log. | Library/Homebrew/test/system_command_spec.rb | @@ -252,5 +252,17 @@
expect(system_command(executable)).to be_a_success
end
end
+
+ context "when given arguments with secrets" do
+ it "does not leak the secrets" do
+ redacted_msg = /#{Regexp.escape("username:******")}/
+ expect do
+ described_class.run! "curl",
+ args: %w[--user username:hunter2],
+ verbose: true,
+ secrets: %w[hunter2]
+ end.to raise_error.with_message(redacted_msg).and output(redacted_msg).to_stdout
+ end
+ end
end
end | true |
Other | Homebrew | brew | 9232ca4508184505f140b3810823872299b480df.json | system_command: allow redacting secrets in the log
Add a new argument `secrets` to specify secret tokens, so we can redact them in the log. | Library/Homebrew/utils.rb | @@ -500,3 +500,7 @@ def tap_and_name_comparison
def command_help_lines(path)
path.read.lines.grep(/^#:/).map { |line| line.slice(2..-1) }
end
+
+def redact_secrets(input, secrets)
+ secrets.reduce(input) { |str, secret| str.gsub secret, "******" }.freeze
+end | true |
Other | Homebrew | brew | f3e15955b3cc698b532b4cbd0c9cd92da49ab2b6.json | formula_creator: remove redundant dep for meson | Library/Homebrew/formula_creator.rb | @@ -96,12 +96,12 @@ class #{Formulary.class_s(name)} < Formula
<% end %>
sha256 "#{sha256}"
<% end %>
+
<% if mode == :cmake %>
depends_on "cmake" => :build
<% elsif mode == :meson %>
depends_on "meson" => :build
depends_on "ninja" => :build
- depends_on "python" => :build
<% elsif mode.nil? %>
# depends_on "cmake" => :build
<% end %> | false |
Other | Homebrew | brew | ba9dde9a4e384cb590718331d74e18da5e78786e.json | python_virtualenv_constants: upgrade virtualenv to 16.6.2 | Library/Homebrew/language/python_virtualenv_constants.rb | @@ -1,8 +1,8 @@
# frozen_string_literal: true
PYTHON_VIRTUALENV_URL =
- "https://files.pythonhosted.org/packages/37/27" \
- "/706af3ee62032933a3217454609c50a5325a6bd9c2c2f495b58c456ba286" \
- "/virtualenv-16.6.1.tar.gz"
+ "https://files.pythonhosted.org/packages/97/f4" \
+ "/64c1853c3b35c1cfa57f3485b49c8c684f9dcaba4e24c56717b83fc66e90" \
+ "/virtualenv-16.6.2.tar.gz"
PYTHON_VIRTUALENV_SHA256 =
- "b7335cddd9260a3dd214b73a2521ffc09647bde3e9457fcca31dc3be3999d04a"
+ "861bbce3a418110346c70f5c7a696fdcf23a261424e1d28aa4f9362fc2ccbc19" | false |
Other | Homebrew | brew | 02b97600af01f8a59566defe27af8673c48edd64.json | bottle_publisher: fix bottle info accessor | Library/Homebrew/bottle_publisher.rb | @@ -107,14 +107,14 @@ def verify_bintray_published(formulae_names)
# Poll for publication completion using a quick partial HEAD, to avoid spurious error messages
# 401 error is normal while file is still in async publishing process
- url = URI(bottle_info.url)
+ url = URI(bottle_info["url"])
puts "Verifying bottle: #{File.basename(url.path)}"
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
retry_count = 0
http.start do
loop do
- req = Net::HTTP::Head.new bottle_info.url
+ req = Net::HTTP::Head.new url
req.initialize_http_header "User-Agent" => HOMEBREW_USER_AGENT_RUBY
res = http.request req
break if res.is_a?(Net::HTTPSuccess) || res.code == "302"
@@ -154,7 +154,7 @@ def verify_bintray_published(formulae_names)
retry_count += 1
end
end
- checksum = Checksum.new(:sha256, bottle_info.sha256)
+ checksum = Checksum.new(:sha256, bottle_info["sha256"])
Pathname.new(filename).verify_checksum(checksum)
end
end | false |
Other | Homebrew | brew | 0ac5cbbda9ddca02da5e0196d29e9ae2a2d6ae98.json | java_dep_if_needed: Install adoptopenjdk for Linux
Install adoptopenjdk rather than openjdk for Linux.
openjdk is superseded by adoptopenjdk. | Library/Homebrew/extend/os/linux/dependency_collector.rb | @@ -4,7 +4,7 @@ class DependencyCollector
def java_dep_if_needed(tags)
req = JavaRequirement.new(tags)
begin
- dep = Dependency.new("openjdk", tags)
+ dep = Dependency.new("adoptopenjdk", tags)
return dep if dep.installed?
return req if req.satisfied?
| false |
Other | Homebrew | brew | 99ed23347abb7a13af38e5af52487d36975550c3.json | formula: update caveats documentation. | Library/Homebrew/formula.rb | @@ -1014,13 +1014,13 @@ def run_post_install
@prefix_returns_versioned_prefix = false
end
- # Tell the user about any Homebrew-specific caveats or locations regarding
- # this package. These should not contain setup instructions that would apply
- # to installation through a different package manager on a different OS.
+ # Warn the user about any Homebrew-specific issues or quirks for this package
+ # These should not contain setup instructions that would apply to installation
+ # through a different package manager on a different OS.
# @return [String]
# <pre>def caveats
# <<~EOS
- # Are optional. Something the user should know?
+ # Are optional. Something the user must be warned about?
# EOS
# end</pre>
# | false |
Other | Homebrew | brew | 9b0b10ca03b10d6886b25c98e5a5a197504c990f.json | Formula Cookbook: use "caveats" name explicitly. | docs/Formula-Cookbook.md | @@ -283,7 +283,7 @@ Homebrew expects to find manual pages in `#{prefix}/share/man/...`, and not in `
Some software installs to `man` instead of `share/man`, so check the output and add a `"--mandir=#{man}"` to the `./configure` line if needed.
-### Special instructions
+### Caveats
In case there are specific issues with the Homebrew packaging (compared to how the software is installed from other sources) a `caveats` block can be added to the formula to warn users. This can indicate non-standard install paths, an example from the `ruby` formula:
| false |
Other | Homebrew | brew | 0980c4150f09c65a3df36c2d2e9a180cc56a9819.json | Docs: add caveat info to cookbook | docs/Formula-Cookbook.md | @@ -283,6 +283,18 @@ Homebrew expects to find manual pages in `#{prefix}/share/man/...`, and not in `
Some software installs to `man` instead of `share/man`, so check the output and add a `"--mandir=#{man}"` to the `./configure` line if needed.
+### Special instructions
+
+In case there are specific issues with the homebrew install a `caveats` block can be added to the formula to inform users. This can indicate non-standard install paths, an example from the ruby formula:
+
+```
+==> Caveats
+By default, binaries installed by gem will be placed into:
+ /usr/local/lib/ruby/gems/bin
+
+You may want to add this to your PATH.
+```
+
### A quick word on naming
Name the formula like the project markets the product. So it’s `pkg-config`, not `pkgconfig`; `sdl_mixer`, not `sdl-mixer` or `sdlmixer`. | false |
Other | Homebrew | brew | 69f4c3fe05ccc130beaa3dc2f92f5180cdbb4646.json | .github/issue-close-app: make message friendlier.
This should hopefully make the experience a little more pleasant when users make an innocent mistake. | .github/issue-close-app.yml | @@ -1,10 +1,10 @@
# Comment that will be sent if an issue is judged to be closed
comment: |
- From the issue template:
+ Whoops, it looks like you created an issue without filling out the checklist and providing all the needed information from one of the issue templates: <https://github.com/Homebrew/homebrew-brew/issues/new/choose>
- > **Please note that we will close your issue without comment if you delete, do not read or do not fill out the issue checklist below and provide ALL the requested information. If you repeatedly fail to use the issue template, we will block you from ever submitting issues to Homebrew again.**
+ As we need all this information to help you we're closing this issue. If you add the necessary information to this issue (don't create a new one, please) then this issue may be reopened.
- If you add the necessary information to this issue (don't create a new one, please) then this issue may be reopened.
+ Sorry!
issueConfigs:
# There can be several configs for different kind of issues.
- content: | false |
Other | Homebrew | brew | 08561335cebcf4cfc6d5459e8fb4c0ea9a52baf8.json | python_virtualenv_constants: upgrade virtualenv to 16.6.1 | Library/Homebrew/language/python_virtualenv_constants.rb | @@ -1,8 +1,8 @@
# frozen_string_literal: true
PYTHON_VIRTUALENV_URL =
- "https://files.pythonhosted.org/packages/53/c0" \
- "/c7819f0bb2cf83e1b4b0d96c901b85191f598a7b534d297c2ef6dc80e2d3" \
- "/virtualenv-16.6.0.tar.gz"
+ "https://files.pythonhosted.org/packages/37/27" \
+ "/706af3ee62032933a3217454609c50a5325a6bd9c2c2f495b58c456ba286" \
+ "/virtualenv-16.6.1.tar.gz"
PYTHON_VIRTUALENV_SHA256 =
- "99acaf1e35c7ccf9763db9ba2accbca2f4254d61d1912c5ee364f9cc4a8942a0"
+ "b7335cddd9260a3dd214b73a2521ffc09647bde3e9457fcca31dc3be3999d04a" | false |
Other | Homebrew | brew | 3cfb028e7f15bc3c51783380d8358b1c7f141ec9.json | Resource#fetch: verify downloads by default.
This API is used internally correctly and externally mostly correctly
but #6230 reveals the external usage is fairly confusing and a bit
unsafe by default. Preserve the existing API while verifying the
checksum by default and providing an opt-out. Using the existing, safe
method will result in a double verification of the checksum which is
harmless. A Homebrew/homebrew-core PR will follow shortly to address
those cases.
Fixes #6230 | Library/Homebrew/cmd/fetch.rb | @@ -133,7 +133,7 @@ def fetch_fetchable(f)
already_fetched = f.cached_download.exist?
begin
- download = f.fetch
+ download = f.fetch(verify_download_integrity: false)
rescue DownloadError
retry if retry_fetch? f
raise | true |
Other | Homebrew | brew | 3cfb028e7f15bc3c51783380d8358b1c7f141ec9.json | Resource#fetch: verify downloads by default.
This API is used internally correctly and externally mostly correctly
but #6230 reveals the external usage is fairly confusing and a bit
unsafe by default. Preserve the existing API while verifying the
checksum by default and providing an opt-out. Using the existing, safe
method will result in a double verification of the checksum which is
harmless. A Homebrew/homebrew-core PR will follow shortly to address
those cases.
Fixes #6230 | Library/Homebrew/dev-cmd/mirror.rb | @@ -47,7 +47,6 @@ def mirror
downloader = f.downloader
downloader.fetch
- f.verify_download_integrity(downloader.cached_location)
filename = downloader.basename
| true |
Other | Homebrew | brew | 3cfb028e7f15bc3c51783380d8358b1c7f141ec9.json | Resource#fetch: verify downloads by default.
This API is used internally correctly and externally mostly correctly
but #6230 reveals the external usage is fairly confusing and a bit
unsafe by default. Preserve the existing API while verifying the
checksum by default and providing an opt-out. Using the existing, safe
method will result in a double verification of the checksum which is
harmless. A Homebrew/homebrew-core PR will follow shortly to address
those cases.
Fixes #6230 | Library/Homebrew/formula.rb | @@ -1688,8 +1688,8 @@ def to_hash
end
# @private
- def fetch
- active_spec.fetch
+ def fetch(verify_download_integrity: true)
+ active_spec.fetch(verify_download_integrity: verify_download_integrity)
end
# @private
@@ -2057,10 +2057,7 @@ def prepare_patches
active_spec.add_legacy_patches(patches) if respond_to?(:patches)
patchlist.grep(DATAPatch) { |p| p.path = path }
-
- patchlist.each do |patch|
- patch.verify_download_integrity(patch.fetch) if patch.external?
- end
+ patchlist.select(&:external?).each(&:fetch)
end
# The methods below define the formula DSL. | true |
Other | Homebrew | brew | 3cfb028e7f15bc3c51783380d8358b1c7f141ec9.json | Resource#fetch: verify downloads by default.
This API is used internally correctly and externally mostly correctly
but #6230 reveals the external usage is fairly confusing and a bit
unsafe by default. Preserve the existing API while verifying the
checksum by default and providing an opt-out. Using the existing, safe
method will result in a double verification of the checksum which is
harmless. A Homebrew/homebrew-core PR will follow shortly to address
those cases.
Fixes #6230 | Library/Homebrew/formula_installer.rb | @@ -948,8 +948,9 @@ def pour
downloader = LocalBottleDownloadStrategy.new(bottle_path)
else
downloader = formula.bottle
- downloader.verify_download_integrity(downloader.fetch)
+ downloader.fetch
end
+
HOMEBREW_CELLAR.cd do
downloader.stage
end | true |
Other | Homebrew | brew | 3cfb028e7f15bc3c51783380d8358b1c7f141ec9.json | Resource#fetch: verify downloads by default.
This API is used internally correctly and externally mostly correctly
but #6230 reveals the external usage is fairly confusing and a bit
unsafe by default. Preserve the existing API while verifying the
checksum by default and providing an opt-out. Using the existing, safe
method will result in a double verification of the checksum which is
harmless. A Homebrew/homebrew-core PR will follow shortly to address
those cases.
Fixes #6230 | Library/Homebrew/resource.rb | @@ -70,17 +70,14 @@ def clear_cache
def stage(target = nil, &block)
raise ArgumentError, "target directory or block is required" unless target || block
- verify_download_integrity(fetch)
+ fetch
prepare_patches
unpack(target, &block)
end
def prepare_patches
patches.grep(DATAPatch) { |p| p.path = owner.owner.path }
-
- patches.each do |patch|
- patch.verify_download_integrity(patch.fetch) if patch.external?
- end
+ patches.select(&:external?).each(&:fetch)
end
def apply_patches
@@ -114,7 +111,7 @@ def files(*files)
Partial.new(self, files)
end
- def fetch
+ def fetch(verify_download_integrity: true)
HOMEBREW_CACHE.mkpath
begin
@@ -123,7 +120,9 @@ def fetch
raise DownloadError.new(self, e)
end
- cached_download
+ download = cached_download
+ verify_download_integrity(download) if verify_download_integrity
+ download
end
def verify_download_integrity(fn) | true |
Other | Homebrew | brew | 7c04c34a88924b1edf9268be9a3faf870b78c080.json | system_config: hide HOMEBREW_BUNDLE_* env vars.
These are being introduced in e.g.
https://github.com/Homebrew/homebrew-bundle/pull/486 and we don't care
about them in Homebrew bug reports. | Library/Homebrew/system_config.rb | @@ -169,6 +169,7 @@ def dump_verbose_config(f = $stdout)
unless ENV["HOMEBREW_ENV"]
ENV.sort.each do |key, value|
next unless key.start_with?("HOMEBREW_")
+ next if key.start_with?("HOMEBREW_BUNDLE_")
next if boring_keys.include?(key)
next if defaults_hash[key.to_sym]
| false |
Other | Homebrew | brew | 57fa2137b29a2f93a478a2038af626c0949fa306.json | audit: check bind for development versions | Library/Homebrew/dev-cmd/audit.rb | @@ -719,6 +719,15 @@ def audit_specs
problem "#{stable.version} is a development release" if minor_version.odd?
end
end
+
+ case formula.name
+ when /bind/
+ version = Version.parse(stable.url)
+ return if version.to_s.split(".").second.to_i.even?
+
+ problem "BIND releases with odd minor version numbers (9.13.x, 9.15.x, etc) are " \
+ "for testing, and can be unstable and are not suitable for general deployment. " \
+ end
end
def audit_revision_and_version_scheme | false |
Other | Homebrew | brew | 11de7de49d272af4f75c5289b28dfce7b735312c.json | rubocops/text: fix long line. | Library/Homebrew/rubocops/text.rb | @@ -16,8 +16,8 @@ def audit_formula(_node, _class_node, _parent_class_node, body_node)
problem "Formulae should not depend on both OpenSSL and LibreSSL (even optionally)."
end
- if depends_on?("veclibfort") || depends_on?("lapack")
- problem "Formulae should use OpenBLAS as the default serial linear algebra library." if formula_tap == "homebrew-core"
+ if formula_tap == "homebrew-core" && (depends_on?("veclibfort") || depends_on?("lapack"))
+ problem "Formulae should use OpenBLAS as the default serial linear algebra library."
end
if method_called_ever?(body_node, :virtualenv_create) || | false |
Other | Homebrew | brew | 65fbcc86d0c51c1ae04a6224b82d8fcf696632d3.json | Add test for MPI choice cop's autocorrect | Library/Homebrew/test/rubocops/lines_spec.rb | @@ -292,6 +292,14 @@ class Foo < Formula
^^^^^^^^^^^^^^^^^^ Use 'depends_on "open-mpi"' instead of 'depends_on "mpich"'.
end
RUBY
+
+ expect_correction(<<~RUBY)
+ class Foo < Formula
+ desc "foo"
+ url 'https://brew.sh/foo-1.0.tgz'
+ depends_on "open-mpi"
+ end
+ RUBY
end
end
end | false |
Other | Homebrew | brew | ffe30058ab2bfbd62c6e3a4e85df6c6cad389a31.json | Add MPICH cop and test
- Split off from PR Homebrew/brew#6209
- Create stand alone class for cop w/ auto-correct | Library/Homebrew/rubocops/lines.rb | @@ -157,6 +157,24 @@ def unless_modifier?(node)
end
end
+ class MpiCheck < FormulaCop
+ def audit_formula(_node, _class_node, _parent_class_node, body_node)
+ # Enforce use of OpenMPI for MPI dependency in core
+ return unless formula_tap == "homebrew-core"
+
+ find_method_with_args(body_node, :depends_on, "mpich") do
+ problem "Use 'depends_on \"open-mpi\"' instead of '#{@offensive_node.source}'."
+ end
+ end
+
+ def autocorrect(node)
+ # The dependency nodes may need to be re-sorted because of this
+ lambda do |corrector|
+ corrector.replace(node.source_range, "depends_on \"open-mpi\"")
+ end
+ end
+ end
+
class Miscellaneous < FormulaCop
def audit_formula(_node, _class_node, _parent_class_node, body_node)
# FileUtils is included in Formula | true |
Other | Homebrew | brew | ffe30058ab2bfbd62c6e3a4e85df6c6cad389a31.json | Add MPICH cop and test
- Split off from PR Homebrew/brew#6209
- Create stand alone class for cop w/ auto-correct | Library/Homebrew/test/rubocops/lines_spec.rb | @@ -279,6 +279,23 @@ def options
end
end
+describe RuboCop::Cop::FormulaAudit::MpiCheck do
+ subject(:cop) { described_class.new }
+
+ context "When auditing formula" do
+ it "reports an offense when using depends_on \"mpich\"" do
+ expect_offense(<<~RUBY, "/homebrew-core/")
+ class Foo < Formula
+ desc "foo"
+ url 'https://brew.sh/foo-1.0.tgz'
+ depends_on "mpich"
+ ^^^^^^^^^^^^^^^^^^ Use 'depends_on "open-mpi"' instead of 'depends_on "mpich"'.
+ end
+ RUBY
+ end
+ end
+end
+
describe RuboCop::Cop::FormulaAudit::Miscellaneous do
subject(:cop) { described_class.new }
| true |
Other | Homebrew | brew | 68288b3495778dcb38e04d28b178b8ac49da0231.json | Add link to rubydoc.brew.sh to docs landing page | docs/README.md | @@ -50,6 +50,7 @@
- [Brew Test Bot For Maintainers](Brew-Test-Bot-For-Core-Contributors.md)
- [Common Issues for Maintainers](Common-Issues-for-Core-Contributors.md)
- [Releases](Releases.md)
+- [Developer/Internal API Documentation](https://rubydoc.brew.sh)
## Governance
| false |
Other | Homebrew | brew | 629c319dc4edee6a8a700351b1ba6fddb5ab73a9.json | pkg-config: add initial support for macOS Catalina | Library/Homebrew/os/mac/pkgconfig/10.15/libcurl.pc | @@ -0,0 +1,39 @@
+#***************************************************************************
+# _ _ ____ _
+# Project ___| | | | _ \| |
+# / __| | | | |_) | |
+# | (__| |_| | _ <| |___
+# \___|\___/|_| \_\_____|
+#
+# Copyright (C) 2001 - 2018, Daniel Stenberg, <daniel@haxx.se>, et al.
+#
+# This software is licensed as described in the file COPYING, which
+# you should have received as part of this distribution. The terms
+# are also available at https://curl.haxx.se/docs/copyright.html.
+#
+# You may opt to use, copy, modify, merge, publish, distribute and/or sell
+# copies of the Software, and permit persons to whom the Software is
+# furnished to do so, under the terms of the COPYING file.
+#
+# This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
+# KIND, either express or implied.
+#
+###########################################################################
+
+# This should most probably benefit from getting a "Requires:" field added
+# dynamically by configure.
+#
+prefix=/usr
+exec_prefix=${prefix}
+libdir=${exec_prefix}/lib
+includedir=${prefix}/include
+supported_protocols="DICT FILE FTP FTPS GOPHER HTTP HTTPS IMAP IMAPS LDAP LDAPS POP3 POP3S RTSP SMB SMBS SMTP SMTPS TELNET TFTP"
+supported_features="AsynchDNS IPv6 Largefile GSS-API Kerberos SPNEGO MultiSSL NTLM NTLM_WB SSL libz HTTP2 UnixSockets HTTPS-proxy"
+
+Name: libcurl
+URL: https://curl.haxx.se/
+Description: Library to transfer files with ftp, http, etc.
+Version: 7.64.1
+Libs: -L${libdir} -lcurl
+Libs.private: -lldap -lz
+Cflags: -I${includedir} | true |
Other | Homebrew | brew | 629c319dc4edee6a8a700351b1ba6fddb5ab73a9.json | pkg-config: add initial support for macOS Catalina | Library/Homebrew/os/mac/pkgconfig/10.15/libexslt.pc | @@ -0,0 +1,12 @@
+prefix=/usr
+exec_prefix=${prefix}
+libdir=${exec_prefix}/lib
+includedir=${prefix}/include
+
+
+Name: libexslt
+Version: 0.8.17
+Description: EXSLT Extension library
+Requires: libxml-2.0
+Libs: -L${libdir} -lexslt -lxslt -lxml2 -lz -lpthread -licucore -lm
+Cflags: -I${includedir} | true |
Other | Homebrew | brew | 629c319dc4edee6a8a700351b1ba6fddb5ab73a9.json | pkg-config: add initial support for macOS Catalina | Library/Homebrew/os/mac/pkgconfig/10.15/libxml-2.0.pc | @@ -0,0 +1,13 @@
+prefix=/usr
+exec_prefix=${prefix}
+libdir=${exec_prefix}/lib
+includedir=${prefix}/include
+modules=1
+
+Name: libXML
+Version: 2.9.4
+Description: libXML library version2.
+Requires:
+Libs: -L${libdir} -lxml2
+Libs.private: -lz -lpthread -licucore -lm
+Cflags: -I${includedir}/libxml2 | true |
Other | Homebrew | brew | 629c319dc4edee6a8a700351b1ba6fddb5ab73a9.json | pkg-config: add initial support for macOS Catalina | Library/Homebrew/os/mac/pkgconfig/10.15/libxslt.pc | @@ -0,0 +1,12 @@
+prefix=/usr
+exec_prefix=${prefix}
+libdir=${exec_prefix}/lib
+includedir=${prefix}/include
+
+
+Name: libxslt
+Version: 1.1.29
+Description: XSLT library version 2.
+Requires: libxml-2.0
+Libs: -L${libdir} -lxslt -lxml2 -lz -lpthread -licucore -lm
+Cflags: -I${includedir} | true |
Other | Homebrew | brew | 629c319dc4edee6a8a700351b1ba6fddb5ab73a9.json | pkg-config: add initial support for macOS Catalina | Library/Homebrew/os/mac/pkgconfig/10.15/sqlite3.pc | @@ -0,0 +1,11 @@
+prefix=/usr
+exec_prefix=${prefix}
+libdir=${exec_prefix}/lib
+includedir=${prefix}/include
+
+Name: SQLite
+Description: SQL database engine
+Version: 3.28.0
+Libs: -L${libdir} -lsqlite3
+Libs.private:
+Cflags: -I${includedir} | true |
Other | Homebrew | brew | 629c319dc4edee6a8a700351b1ba6fddb5ab73a9.json | pkg-config: add initial support for macOS Catalina | Library/Homebrew/os/mac/pkgconfig/10.15/uuid.pc | @@ -0,0 +1,13 @@
+prefix=/usr
+exec_prefix=${prefix}
+libdir=${exec_prefix}/lib
+sharedlibdir=${libdir}
+includedir=${prefix}/include
+
+Name: uuid
+Description: Universally unique id library
+Version: 1.0
+
+Requires:
+Libs:
+Cflags: -I${includedir}/uuid | true |
Other | Homebrew | brew | 629c319dc4edee6a8a700351b1ba6fddb5ab73a9.json | pkg-config: add initial support for macOS Catalina | Library/Homebrew/os/mac/pkgconfig/10.15/zlib.pc | @@ -0,0 +1,13 @@
+prefix=/usr
+exec_prefix=${prefix}
+libdir=${exec_prefix}/lib
+sharedlibdir=${libdir}
+includedir=${prefix}/include
+
+Name: zlib
+Description: zlib compression library
+Version: 1.2.11
+
+Requires:
+Libs: -L${libdir} -L${sharedlibdir} -lz
+Cflags: -I${includedir} | true |
Other | Homebrew | brew | 2a5aee0a0b98f40d6936d124c67cc3ec33d6ee03.json | xcode: add initial support for Xcode 11.0 | Library/Homebrew/os/mac.rb | @@ -37,7 +37,7 @@ def full_version=(version)
def latest_sdk_version
# TODO: bump version when new Xcode macOS SDK is released
- Version.new "10.14"
+ Version.new "10.15"
end
def latest_stable_version
@@ -208,6 +208,7 @@ def preferred_arch
"10.1" => { clang: "10.0", clang_build: 1000 },
"10.2" => { clang: "10.0", clang_build: 1001 },
"10.2.1" => { clang: "10.0", clang_build: 1001 },
+ "11.0" => { clang: "11.0", clang_build: 1100 },
}.freeze
def compilers_standard? | true |
Other | Homebrew | brew | 2a5aee0a0b98f40d6936d124c67cc3ec33d6ee03.json | xcode: add initial support for Xcode 11.0 | Library/Homebrew/os/mac/xcode.rb | @@ -17,16 +17,18 @@ def latest_version
when "10.12" then "9.2"
when "10.13" then "10.1"
when "10.14" then "10.2.1"
+ when "10.15" then "11.0"
else
raise "macOS '#{MacOS.version}' is invalid" unless OS::Mac.prerelease?
# Default to newest known version of Xcode for unreleased macOS versions.
- "10.2.1"
+ "11.0"
end
end
def minimum_version
case MacOS.version
+ when "10.15" then "11.0"
when "10.14" then "10.2"
when "10.13" then "9.0"
when "10.12" then "8.0"
@@ -174,7 +176,8 @@ def detect_version_from_clang_version
when 90 then "9.2"
when 91 then "9.4"
when 100 then "10.2.1"
- else "10.2.1"
+ when 110 then "11.0"
+ else "11.0"
end
end
@@ -242,6 +245,7 @@ def latest_version
# on the older supported platform for that Xcode release, i.e there's no
# CLT package for 10.11 that contains the Clang version from Xcode 8.
case MacOS.version
+ when "10.15" then "1100.0.20.17"
when "10.14" then "1001.0.46.4"
when "10.13" then "1000.10.44.2"
when "10.12" then "900.0.39.2"
@@ -253,6 +257,7 @@ def latest_version
def minimum_version
case MacOS.version
+ when "10.15" then "11.0.0"
when "10.14" then "10.0.0"
when "10.13" then "9.0.0"
when "10.12" then "8.0.0" | true |
Other | Homebrew | brew | b2969e6063a923e03a4376785fa476807ebab6f0.json | Add needs_linux tag to specs that fails on MacOS | Library/Homebrew/software_spec.rb | @@ -171,7 +171,7 @@ def depends_on(spec)
end
def uses_from_macos(deps, **_args)
- deps.is_a?(Hash) && deps = Hash[*deps.shift]
+ deps = Hash[*deps.shift] if deps.is_a?(Hash)
depends_on(deps)
end | true |
Other | Homebrew | brew | b2969e6063a923e03a4376785fa476807ebab6f0.json | Add needs_linux tag to specs that fails on MacOS | Library/Homebrew/test/os/linux/software_spec_spec.rb | @@ -1,35 +0,0 @@
-# frozen_string_literal: true
-
-require "software_spec"
-
-describe SoftwareSpec do
- subject(:spec) { described_class.new }
-
- describe "#uses_from_macos" do
- before do
- allow(OS).to receive(:linux?).and_return(true)
- end
-
- it "allows specifying dependencies" do
- spec.uses_from_macos("foo")
-
- expect(spec.deps.first.name).to eq("foo")
- end
-
- it "works with tags" do
- spec.uses_from_macos("foo" => :head, :after => :mojave)
-
- expect(spec.deps.first.name).to eq("foo")
- expect(spec.deps.first.tags).to include(:head)
- end
-
- it "ignores OS version specifications" do
- spec.uses_from_macos("foo", after: :mojave)
- spec.uses_from_macos("bar" => :head, :after => :mojave)
-
- expect(spec.deps.first.name).to eq("foo")
- expect(spec.deps.last.name).to eq("bar")
- expect(spec.deps.last.tags).to include(:head)
- end
- end
-end | true |
Other | Homebrew | brew | b2969e6063a923e03a4376785fa476807ebab6f0.json | Add needs_linux tag to specs that fails on MacOS | Library/Homebrew/test/software_spec_spec.rb | @@ -132,6 +132,30 @@
end
end
+ describe "#uses_from_macos" do
+ it "allows specifying dependencies", :needs_linux do
+ spec.uses_from_macos("foo")
+
+ expect(spec.deps.first.name).to eq("foo")
+ end
+
+ it "works with tags", :needs_linux do
+ spec.uses_from_macos("foo" => :head, :after => :mojave)
+
+ expect(spec.deps.first.name).to eq("foo")
+ expect(spec.deps.first.tags).to include(:head)
+ end
+
+ it "ignores OS version specifications", :needs_linux do
+ spec.uses_from_macos("foo", after: :mojave)
+ spec.uses_from_macos("bar" => :head, :after => :mojave)
+
+ expect(spec.deps.first.name).to eq("foo")
+ expect(spec.deps.last.name).to eq("bar")
+ expect(spec.deps.last.tags).to include(:head)
+ end
+ end
+
specify "explicit options override defaupt depends_on option description" do
subject.option("with-foo", "blah")
subject.depends_on("foo" => :optional) | true |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.