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
f4707a8041181133c92b2beca88a39ec92137e19.json
upgrade: reject formulae checked in earlier levels
Library/Homebrew/cmd/upgrade.rb
@@ -255,7 +255,7 @@ def upgradable_dependents(kegs, formulae) [formulae_to_upgrade, formulae_pinned] end - def broken_dependents(kegs, formulae) + def broken_dependents(kegs, formulae, scanned = []) formulae_to_reinstall = Set.new formulae_pinned_and_outdated = Set.new @@ -266,6 +266,8 @@ def broken_dependents(kegs, formulae) dependents = kegs.select do |keg| keg.runtime_dependencies .any? { |d| d["full_name"] == formula.full_name } + end.reject do |keg| + scanned.include?(keg) end next if dependents.empty? @@ -290,7 +292,9 @@ def broken_dependents(kegs, formulae) descendants << f end - descendants_to_reinstall, descendants_pinned = broken_dependents(kegs, descendants) + scanned << dependents + + descendants_to_reinstall, descendants_pinned = broken_dependents(kegs, descendants, scanned) formulae_to_reinstall.merge descendants_to_reinstall formulae_pinned_and_outdated.merge descendants_pinned
false
Other
Homebrew
brew
953a1bf20b6944ef14bd9f6e5f5bc37ed191eba8.json
Add quotes around the brew invocation
docs/Shell-Completion.md
@@ -12,7 +12,7 @@ To make Homebrew's completions available in `bash`, you must source the definiti ```sh if type brew &>/dev/null; then - HOMEBREW_PREFIX=$(brew --prefix) + HOMEBREW_PREFIX="$(brew --prefix)" if [[ -r "${HOMEBREW_PREFIX}/etc/profile.d/bash_completion.sh" ]]; then source "${HOMEBREW_PREFIX}/etc/profile.d/bash_completion.sh" else
false
Other
Homebrew
brew
24ef7fa5c8eb8e313a7169e4a55f88e21dea277b.json
remove xattr unsupported option in macOS 10.15
Library/Homebrew/cask/quarantine.rb
@@ -154,7 +154,6 @@ def propagate(from: nil, to: nil) "--", xattr, "-w", - "-s", QUARANTINE_ATTRIBUTE, quarantine_status, ],
false
Other
Homebrew
brew
c6cb20a768eba296396b8c7879434cde3916cdef.json
Fix frozen string bug
Library/Homebrew/exceptions.rb
@@ -466,7 +466,7 @@ def initialize(flags, bottled: true) require_text = "requires" end - message = <<~EOS + message = +<<~EOS The following #{flag_text}: #{flags.join(", ")} #{require_text} building tools, but none are installed.
true
Other
Homebrew
brew
c6cb20a768eba296396b8c7879434cde3916cdef.json
Fix frozen string bug
Library/Homebrew/test/exceptions_spec.rb
@@ -225,3 +225,9 @@ class Baz < Formula; end its(:to_s) { is_expected.to match(/This bottle does not contain the formula file/) } end + +describe BuildFlagsError do + subject { described_class.new(["-s"]) } + + its(:to_s) { is_expected.to match(/flag:\s+-s\nrequires building tools/) } +end
true
Other
Homebrew
brew
86feb5a9deeffbf0b41850098c0fd3505d8a1673.json
audit: replace depends_on with uses_from_macos
Library/Homebrew/dev-cmd/audit.rb
@@ -394,8 +394,8 @@ def audit_deps dep_f.keg_only_reason.valid? && !%w[apr apr-util openblas openssl openssl@1.1].include?(dep.name) new_formula_problem( - "Dependency '#{dep.name}' may be unnecessary as it is provided " \ - "by macOS; try to build this formula without it.", + "Dependency '#{dep.name}' is provided by macOS; " \ + "please replace 'depends_on' with 'uses_from_macos'.", ) end
true
Other
Homebrew
brew
86feb5a9deeffbf0b41850098c0fd3505d8a1673.json
audit: replace depends_on with uses_from_macos
Library/Homebrew/test/dev-cmd/audit_spec.rb
@@ -316,7 +316,7 @@ class Foo < Formula fa.audit_deps end - its(:new_formula_problems) { are_expected.to match([/unnecessary/]) } + its(:new_formula_problems) { are_expected.to match([/is provided by macOS/]) } end end end
true
Other
Homebrew
brew
209d12b89f5a43d8aa69747307965d301c3d6e38.json
vendor-install: remove ARM bottles until built.
Library/Homebrew/cmd/vendor-install.sh
@@ -29,16 +29,6 @@ then ruby_URL2="https://github.com/Homebrew/homebrew-portable-ruby/releases/download/2.6.3/portable-ruby--2.6.3.x86_64_linux.bottle.tar.gz" ruby_SHA="e8c9b6d3dc5f40844e07b4b694897b8b7cb5a7dab1013b3b8712a22868f98c98" ;; - aarch64) - ruby_URL="$HOMEBREW_BOTTLE_DOMAIN/bottles-portable-ruby/portable-ruby-2.3.7.aarch64_linux.bottle.tar.gz" - ruby_URL2="https://github.com/Homebrew/homebrew-portable-ruby/releases/download/2.3.7/portable-ruby-2.3.7.aarch64_linux.bottle.tar.gz" - ruby_SHA="e5a72a9deabe500d5d2eaed29e2eb84868ade962eda3ddc68ea169adbb7ac5a2" - ;; - armv[67]*) - ruby_URL="$HOMEBREW_BOTTLE_DOMAIN/bottles-portable-ruby/portable-ruby-2.3.7.armv6_linux.bottle.tar.gz" - ruby_URL2="https://github.com/Homebrew/homebrew-portable-ruby/releases/download/2.3.7/portable-ruby-2.3.7.armv6_linux.bottle.tar.gz" - ruby_SHA="17dce8965d7c935ec1dd0c5bb0be937b685ffe65529141d9e6ed78f4925b4570" - ;; esac fi
false
Other
Homebrew
brew
157a9191e3505d3b2eba1954143875787a7434d1.json
Fix minor typo in How-to-Create-and-Maintain-a-Tap
docs/How-to-Create-and-Maintain-a-Tap.md
@@ -37,7 +37,7 @@ If they want to get your tap without installing any formula at the same time, users can add it with the [`brew tap` command](Taps.md). If it’s on GitHub, they can use `brew tap user/repo`, where `user` is your -GitHub username and `homebrew-repo` your repository. +GitHub username and `homebrew-repo` is your repository. If it’s hosted outside of GitHub, they have to use `brew tap user/repo <URL>`, where `user` and `repo` will be used to refer to your tap and `<URL>` is your
false
Other
Homebrew
brew
69c1b4fcf984c6da97534a59bd917d3ddd14936c.json
subversion_spec: fix svnadmin calls on Linux. Ensure that we only use `xcrun` on Catalina or newer.
Library/Homebrew/test/unpack_strategy/subversion_spec.rb
@@ -8,7 +8,9 @@ let(:path) { working_copy } before do - safe_system "xcrun", "svnadmin", "create", repo + svnadmin = ["svnadmin"] + svnadmin = ["xcrun", *svnadmin] if OS.mac? && MacOS.version >= :catalina + safe_system(*svnadmin, "create", repo) safe_system "svn", "checkout", "file://#{repo}", working_copy FileUtils.touch working_copy/"test"
false
Other
Homebrew
brew
cf34e1bec8f6579b9c22935581163430d8ffb780.json
os/mac/diagnostic: allow Ruby 2.6.3 on Catalina.
Library/Homebrew/extend/os/mac/diagnostic.rb
@@ -139,7 +139,11 @@ def check_if_xcode_needs_clt_installed end def check_ruby_version - ruby_version = "2.3.7" + ruby_version = if MacOS.version >= :catalina + "2.6.3" + else + "2.3.7" + end return if RUBY_VERSION == ruby_version return if ARGV.homebrew_developer? && OS::Mac.prerelease?
false
Other
Homebrew
brew
36bc11b01a1f4bd8d8364842e7d477c6f285cddb.json
utils/shell: match preferred shell by symbol.
Library/Homebrew/utils/shell.rb
@@ -39,8 +39,8 @@ def export_value(key, value, shell = preferred) # return the shell profile file based on user's preferred shell def profile - return "#{ENV["ZDOTDIR"]}/.zshrc" if preferred == "zsh" && ENV["ZDOTDIR"].present? - + return "#{ENV["ZDOTDIR"]}/.zshrc" if preferred == :zsh && ENV["ZDOTDIR"].present? + SHELL_PROFILE_MAP.fetch(preferred, "~/.bash_profile") end
false
Other
Homebrew
brew
9fc495125dd730319014983903cbcdb3db5c746e.json
audit: add gcab 1.3 to whitelist
Library/Homebrew/dev-cmd/audit.rb
@@ -759,6 +759,7 @@ def audit_specs pygtkglext 1.1.0 gtk-mac-integration 2.1.3 gtk-doc 1.31 + gcab 1.3 ].each_slice(2).to_a.map do |formula, version| [formula, version.split(".")[0..1].join(".")] end
false
Other
Homebrew
brew
bb2c835025ebf44616df814f06b3f185f30c035f.json
Installation: recommend High Sierra and newer.
docs/Installation.md
@@ -11,7 +11,7 @@ it does it too. You have to confirm everything it will do before it starts. ## macOS Requirements * A 64-bit Intel CPU <sup>[1](#1)</sup> -* macOS 10.12 (or higher) <sup>[2](#2)</sup> +* macOS High Sierra (10.13) (or higher) <sup>[2](#2)</sup> * Command Line Tools (CLT) for Xcode: `xcode-select --install`, [developer.apple.com/downloads](https://developer.apple.com/downloads) or [Xcode](https://itunes.apple.com/us/app/xcode/id497799835) <sup>[3](#3)</sup> @@ -51,7 +51,7 @@ Uninstallation is documented in the [FAQ](FAQ.md). <a name="1"><sup>1</sup></a> For 32-bit or PPC support see [Tigerbrew](https://github.com/mistydemeo/tigerbrew). -<a name="2"><sup>2</sup></a> 10.12 or higher is recommended. 10.9–10.11 are +<a name="2"><sup>2</sup></a> 10.13 or higher is recommended. 10.9–10.12 are supported on a best-effort basis. For 10.4-10.6 see [Tigerbrew](https://github.com/mistydemeo/tigerbrew).
false
Other
Homebrew
brew
1cd75e4298be0b11185506cb16d67497d335f91c.json
sandbox: allow more TTYs. This is needed on Catalina. Fixes #6546
Library/Homebrew/sandbox.rb
@@ -163,7 +163,7 @@ class SandboxProfile (literal "/dev/random") (literal "/dev/zero") (regex #"^/dev/fd/[0-9]+$") - (regex #"^/dev/ttys?[0-9]*$") + (regex #"^/dev/tty[a-z0-9]*$") ) (deny file-write*) ; deny non-whitelist file write operations (allow process-exec
false
Other
Homebrew
brew
8ec48b0c72c24c90c7deee594264591feb808549.json
Fix symlink validation in Mojave
Library/Homebrew/unpack_strategy/dmg.rb
@@ -29,7 +29,7 @@ def dmg_metadata? # symlinks to system directories (commonly to /Applications) def system_dir_symlink? - symlink? && MacOS.system_dir?(readlink) + symlink? && MacOS.system_dir?(realpath) end def bom
false
Other
Homebrew
brew
7855bb88b6d25b34b43b56f5373e8830565645e6.json
Add cask instructions to tap docs Loosely based on (now deleted) https://github.com/Homebrew/homebrew-cask/blob/4c72606867d7aa92987c550082769d0f20e6121c/doc/alternate_cask_taps.md Cask naming issues are from experimentation.
docs/How-to-Create-and-Maintain-a-Tap.md
@@ -1,7 +1,7 @@ # How to Create and Maintain a Tap -[Taps](Taps.md) are external sources of Homebrew formulae and/or external commands. They -can be created by anyone to provide their own formulae and/or external commands +[Taps](Taps.md) are external sources of Homebrew formulae, casks and/or external commands. They +can be created by anyone to provide their own formulae, casks and/or external commands to any Homebrew user. ## Creating a tap @@ -58,6 +58,19 @@ Once your tap is installed, Homebrew will update it each time a user runs `brew update`. Outdated formulae will be upgraded when a user runs `brew upgrade`, like core formulae. +## Casks + +Casks can also be installed from a tap. +Casks can be included in taps with formulae, or in a tap with just casks. +Place any cask files you wish to make available in a `Casks` directory at the top level of your tap. + +See [homebrew/cask](https://github.com/Homebrew/homebrew-cask) for an example of a tap with a `Casks` subdirectory. + +### Naming + +Unlike formulae, casks must have globally unique names to avoid clashes. +This can be achieved by e.g. prepending the cask name with you github username: `username-formula-name`. + ## External commands You can provide your tap users with custom `brew` commands by adding them in a
false
Other
Homebrew
brew
8ff2e9ae4ea2ada3df9fbcedda8f6fc86c06265f.json
Improve speed of HOMEBREW_AUTO_UPDATE_SECS This variable allows a user to configure how often `brew update` runs. With the previous implementation, however, it was still pretty slow as it would run some of `brew update` even within the timeout. This feels related to complaints about Homebrew "feeling slow" since we enabled this. Address this by: - making `HOMEBREW_AUTO_UPDATE_SECS` behave more like `HOMEBREW_NO_AUTO_UPDATE` and entirely skip the invocation of `brew update` if the relevant tap (homebrew-core or homebrew-cask depending on command invoked) has been checked in the last `HOMEBREW_AUTO_UPDATE_SECS` - Only require/check the update of a single tap rather than every tap - Increase the default value of `HOMEBREW_AUTO_UPDATE_SECS` from 1m to 5m to cut people a bit more slack. We're not updating things often enough for 1m not to feel a bit overkill and 5m feels appropriate for a Homebrew "session" to only require a single update.
Library/Homebrew/brew.sh
@@ -466,6 +466,20 @@ update-preinstall() { then export HOMEBREW_AUTO_UPDATING="1" + # Skip auto-update if the cask/core tap has been updated in the + # last $HOMEBREW_AUTO_UPDATE_SECS. + if [[ "$HOMEBREW_COMMAND" = "cask" ]] + then + tap_fetch_head="$HOMEBREW_LIBRARY/Taps/homebrew/homebrew-cask/.git/FETCH_HEAD" + else + tap_fetch_head="$HOMEBREW_LIBRARY/Taps/homebrew/homebrew-core/.git/FETCH_HEAD" + fi + if [[ -f "$tap_fetch_head" && + -n "$(find "$tap_fetch_head" -type f -mtime -"${HOMEBREW_AUTO_UPDATE_SECS}"s 2>/dev/null)" ]] + then + return + fi + if [[ -z "$HOMEBREW_VERBOSE" ]] then update-preinstall-timer &
true
Other
Homebrew
brew
8ff2e9ae4ea2ada3df9fbcedda8f6fc86c06265f.json
Improve speed of HOMEBREW_AUTO_UPDATE_SECS This variable allows a user to configure how often `brew update` runs. With the previous implementation, however, it was still pretty slow as it would run some of `brew update` even within the timeout. This feels related to complaints about Homebrew "feeling slow" since we enabled this. Address this by: - making `HOMEBREW_AUTO_UPDATE_SECS` behave more like `HOMEBREW_NO_AUTO_UPDATE` and entirely skip the invocation of `brew update` if the relevant tap (homebrew-core or homebrew-cask depending on command invoked) has been checked in the last `HOMEBREW_AUTO_UPDATE_SECS` - Only require/check the update of a single tap rather than every tap - Increase the default value of `HOMEBREW_AUTO_UPDATE_SECS` from 1m to 5m to cut people a bit more slack. We're not updating things often enough for 1m not to feel a bit overkill and 5m feels appropriate for a Homebrew "session" to only require a single update.
Library/Homebrew/cmd/update.sh
@@ -337,7 +337,7 @@ EOS if [[ -z "$HOMEBREW_AUTO_UPDATE_SECS" ]] then - HOMEBREW_AUTO_UPDATE_SECS="60" + HOMEBREW_AUTO_UPDATE_SECS="300" fi # check permissions @@ -451,12 +451,6 @@ EOS # origin branch name is, and use that. If not set, fall back to "master". # the refspec ensures that the default upstream branch gets updated ( - if [[ -n "$HOMEBREW_UPDATE_PREINSTALL" ]] - then - # Skip taps checked/fetched recently - [[ -n "$(find "$DIR/.git/FETCH_HEAD" -type f -mtime -"${HOMEBREW_AUTO_UPDATE_SECS}"s 2>/dev/null)" ]] && exit - fi - UPSTREAM_REPOSITORY_URL="$(git config remote.origin.url)" if [[ "$UPSTREAM_REPOSITORY_URL" = "https://github.com/"* ]] then
true
Other
Homebrew
brew
8ff2e9ae4ea2ada3df9fbcedda8f6fc86c06265f.json
Improve speed of HOMEBREW_AUTO_UPDATE_SECS This variable allows a user to configure how often `brew update` runs. With the previous implementation, however, it was still pretty slow as it would run some of `brew update` even within the timeout. This feels related to complaints about Homebrew "feeling slow" since we enabled this. Address this by: - making `HOMEBREW_AUTO_UPDATE_SECS` behave more like `HOMEBREW_NO_AUTO_UPDATE` and entirely skip the invocation of `brew update` if the relevant tap (homebrew-core or homebrew-cask depending on command invoked) has been checked in the last `HOMEBREW_AUTO_UPDATE_SECS` - Only require/check the update of a single tap rather than every tap - Increase the default value of `HOMEBREW_AUTO_UPDATE_SECS` from 1m to 5m to cut people a bit more slack. We're not updating things often enough for 1m not to feel a bit overkill and 5m feels appropriate for a Homebrew "session" to only require a single update.
Library/Homebrew/manpages/brew.1.md.erb
@@ -134,7 +134,7 @@ Note that environment variables must have a value set to be detected. For exampl * `HOMEBREW_AUTO_UPDATE_SECS`: If set, Homebrew will only check for autoupdates once per this seconds interval. - *Default:* `60`. + *Default:* `300`. * `HOMEBREW_AWS_ACCESS_KEY_ID`, `HOMEBREW_AWS_SECRET_ACCESS_KEY`: When using the `S3` download strategy, Homebrew will look in
true
Other
Homebrew
brew
8ff2e9ae4ea2ada3df9fbcedda8f6fc86c06265f.json
Improve speed of HOMEBREW_AUTO_UPDATE_SECS This variable allows a user to configure how often `brew update` runs. With the previous implementation, however, it was still pretty slow as it would run some of `brew update` even within the timeout. This feels related to complaints about Homebrew "feeling slow" since we enabled this. Address this by: - making `HOMEBREW_AUTO_UPDATE_SECS` behave more like `HOMEBREW_NO_AUTO_UPDATE` and entirely skip the invocation of `brew update` if the relevant tap (homebrew-core or homebrew-cask depending on command invoked) has been checked in the last `HOMEBREW_AUTO_UPDATE_SECS` - Only require/check the update of a single tap rather than every tap - Increase the default value of `HOMEBREW_AUTO_UPDATE_SECS` from 1m to 5m to cut people a bit more slack. We're not updating things often enough for 1m not to feel a bit overkill and 5m feels appropriate for a Homebrew "session" to only require a single update.
docs/Manpage.md
@@ -1068,7 +1068,7 @@ Note that environment variables must have a value set to be detected. For exampl * `HOMEBREW_AUTO_UPDATE_SECS`: If set, Homebrew will only check for autoupdates once per this seconds interval. - *Default:* `60`. + *Default:* `300`. * `HOMEBREW_AWS_ACCESS_KEY_ID`, `HOMEBREW_AWS_SECRET_ACCESS_KEY`: When using the `S3` download strategy, Homebrew will look in
true
Other
Homebrew
brew
8ff2e9ae4ea2ada3df9fbcedda8f6fc86c06265f.json
Improve speed of HOMEBREW_AUTO_UPDATE_SECS This variable allows a user to configure how often `brew update` runs. With the previous implementation, however, it was still pretty slow as it would run some of `brew update` even within the timeout. This feels related to complaints about Homebrew "feeling slow" since we enabled this. Address this by: - making `HOMEBREW_AUTO_UPDATE_SECS` behave more like `HOMEBREW_NO_AUTO_UPDATE` and entirely skip the invocation of `brew update` if the relevant tap (homebrew-core or homebrew-cask depending on command invoked) has been checked in the last `HOMEBREW_AUTO_UPDATE_SECS` - Only require/check the update of a single tap rather than every tap - Increase the default value of `HOMEBREW_AUTO_UPDATE_SECS` from 1m to 5m to cut people a bit more slack. We're not updating things often enough for 1m not to feel a bit overkill and 5m feels appropriate for a Homebrew "session" to only require a single update.
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" "September 2019" "Homebrew" "brew-cask" +.TH "BREW\-CASK" "1" "October 2019" "Homebrew" "brew-cask" . .SH "NAME" \fBbrew\-cask\fR \- a friendly binary installer for macOS
true
Other
Homebrew
brew
8ff2e9ae4ea2ada3df9fbcedda8f6fc86c06265f.json
Improve speed of HOMEBREW_AUTO_UPDATE_SECS This variable allows a user to configure how often `brew update` runs. With the previous implementation, however, it was still pretty slow as it would run some of `brew update` even within the timeout. This feels related to complaints about Homebrew "feeling slow" since we enabled this. Address this by: - making `HOMEBREW_AUTO_UPDATE_SECS` behave more like `HOMEBREW_NO_AUTO_UPDATE` and entirely skip the invocation of `brew update` if the relevant tap (homebrew-core or homebrew-cask depending on command invoked) has been checked in the last `HOMEBREW_AUTO_UPDATE_SECS` - Only require/check the update of a single tap rather than every tap - Increase the default value of `HOMEBREW_AUTO_UPDATE_SECS` from 1m to 5m to cut people a bit more slack. We're not updating things often enough for 1m not to feel a bit overkill and 5m feels appropriate for a Homebrew "session" to only require a single update.
manpages/brew.1
@@ -1329,7 +1329,7 @@ If set, instructs Homebrew to prefix all download URLs, including those for bott If set, Homebrew will only check for autoupdates once per this seconds interval\. . .IP -\fIDefault:\fR \fB60\fR\. +\fIDefault:\fR \fB300\fR\. . .TP \fBHOMEBREW_AWS_ACCESS_KEY_ID\fR, \fBHOMEBREW_AWS_SECRET_ACCESS_KEY\fR
true
Other
Homebrew
brew
caf7df5840d9507ff99fcf8385ffa1f42ada6e2d.json
Cask: add doctor check for xattr CC: Homebrew/homebrew-cask#69660
Library/Homebrew/cask/cmd/doctor.rb
@@ -25,6 +25,7 @@ def summary_header def run check_software_versions + check_xattr check_quarantine_support check_install_location check_staging_location @@ -121,6 +122,29 @@ def check_environment_variables (locale_variables + environment_variables).sort.each(&method(:render_env_var)) end + def check_xattr + ohai "xattr issues" + result = system_command "/usr/bin/xattr" + + if result.status.success? + puts none_string + elsif result.stderr.match? "ImportError: No module named pkg_resources" + result = system_command "/usr/bin/python", "--version" + + if result.stdout.match? "Python 2.7" + add_error "Your Python installation has a broken version of setuptools." + add_error "To fix, reinstall macOS or run 'sudo /usr/bin/python -m pip install -I setuptools'." + else + add_error "The system Python version is wrong." + add_error "To fix, run 'defaults write com.apple.versioner.python Version 2.7'." + end + elsif result.stderr.match? "pkg_resources.DistributionNotFound" + add_error "Your Python installation is unable to find xattr." + else + add_error "unknown xattr error: #{result.stderr.first}" + end + end + def check_quarantine_support ohai "Gatekeeper support"
false
Other
Homebrew
brew
eeaadc114823d4c130079536da1a3ecae030adc5.json
README: remove Azure Pipelines badge. We're using GitHub Actions now.
README.md
@@ -19,8 +19,6 @@ Second, read the [Troubleshooting Checklist](https://docs.brew.sh/Troubleshootin **If you don't read these it will take us far longer to help you with your problem.** ## Contributing -[![Azure Pipelines](https://img.shields.io/vso/build/Homebrew/56a87eb4-3180-495a-9117-5ed6c79da737/1.svg)](https://dev.azure.com/Homebrew/Homebrew/_build/latest?definitionId=1) - We'd love you to contribute to Homebrew. First, please read our [Contribution Guide](CONTRIBUTING.md) and [Code of Conduct](https://github.com/Homebrew/.github/blob/master/CODE_OF_CONDUCT.md#code-of-conduct). We explicitly welcome contributions from people who have never contributed to open-source before: we were all beginners once! We can help build on a partially working pull request with the aim of getting it merged. We are also actively seeking to diversify our contributors and especially welcome contributions from women from all backgrounds and people of colour.
false
Other
Homebrew
brew
8ff7601a92b9200c660706d60e04aa63200baa73.json
define default prefix constants also use them to detect if prefix line in bottle block is needed
Library/Homebrew/dev-cmd/bottle.rb
@@ -16,7 +16,7 @@ <% if !root_url.start_with?(HOMEBREW_BOTTLE_DEFAULT_DOMAIN) %> root_url "<%= root_url %>" <% end %> - <% if ![Homebrew::DEFAULT_PREFIX, "/usr/local"].include?(prefix) %> + <% if ![HOMEBREW_DEFAULT_PREFIX, LINUXBREW_DEFAULT_PREFIX].include?(prefix) %> prefix "<%= prefix %>" <% end %> <% if cellar.is_a? Symbol %>
true
Other
Homebrew
brew
8ff7601a92b9200c660706d60e04aa63200baa73.json
define default prefix constants also use them to detect if prefix line in bottle block is needed
Library/Homebrew/global.rb
@@ -52,14 +52,17 @@ HOMEBREW_BOTTLE_DEFAULT_DOMAIN = ENV["HOMEBREW_BOTTLE_DEFAULT_DOMAIN"] HOMEBREW_BOTTLE_DOMAIN = ENV["HOMEBREW_BOTTLE_DOMAIN"] +HOMEBREW_DEFAULT_PREFIX = "/usr/local" +LINUXBREW_DEFAULT_PREFIX = "/home/linuxbrew/.linuxbrew" + require "fileutils" require "os" require "os/global" module Homebrew extend FileUtils - DEFAULT_PREFIX ||= "/usr/local" + DEFAULT_PREFIX ||= HOMEBREW_DEFAULT_PREFIX DEFAULT_CELLAR = "#{DEFAULT_PREFIX}/Cellar" DEFAULT_REPOSITORY = "#{DEFAULT_PREFIX}/Homebrew"
true
Other
Homebrew
brew
8ff7601a92b9200c660706d60e04aa63200baa73.json
define default prefix constants also use them to detect if prefix line in bottle block is needed
Library/Homebrew/os/linux/global.rb
@@ -2,8 +2,8 @@ module Homebrew DEFAULT_PREFIX ||= if ENV["HOMEBREW_FORCE_HOMEBREW_ON_LINUX"] - "/usr/local" + HOMEBREW_DEFAULT_PREFIX else - "/home/linuxbrew/.linuxbrew" + LINUXBREW_DEFAULT_PREFIX end.freeze end
true
Other
Homebrew
brew
b31b14f7869c921f95f46d563ae13034113b5fe6.json
cat: use HOMEBREW_VISUAL as pager if set
Library/Homebrew/cmd/cat.rb
@@ -25,6 +25,7 @@ def cat raise "`brew cat` doesn't support multiple arguments" if args.remaining.size > 1 cd HOMEBREW_REPOSITORY - safe_system "cat", formulae.first.path, *Homebrew.args.passthrough + pager = ENV["HOMEBREW_VISUAL"] || "cat" + safe_system pager, formulae.first.path, *Homebrew.args.passthrough end end
false
Other
Homebrew
brew
eb9a31b52b0643b3b88f75ce509145fe45fdd18d.json
requirement_spec: use describe correctly.
Library/Homebrew/test/requirement_spec.rb
@@ -39,7 +39,7 @@ end describe "#fatal?" do - context "#fatal true is specified" do + describe "#fatal true is specified" do let(:klass) do Class.new(described_class) do fatal true @@ -49,13 +49,13 @@ it { is_expected.to be_fatal } end - context "#fatal is omitted" do + describe "#fatal is omitted" do it { is_expected.not_to be_fatal } end end describe "#satisfied?" do - context "#satisfy with block and build_env returns true" do + describe "#satisfy with block and build_env returns true" do let(:klass) do Class.new(described_class) do satisfy(build_env: false) do @@ -67,7 +67,7 @@ it { is_expected.to be_satisfied } end - context "#satisfy with block and build_env returns false" do + describe "#satisfy with block and build_env returns false" do let(:klass) do Class.new(described_class) do satisfy(build_env: false) do @@ -79,7 +79,7 @@ it { is_expected.not_to be_satisfied } end - context "#satisfy returns true" do + describe "#satisfy returns true" do let(:klass) do Class.new(described_class) do satisfy true @@ -89,7 +89,7 @@ it { is_expected.to be_satisfied } end - context "#satisfy returns false" do + describe "#satisfy returns false" do let(:klass) do Class.new(described_class) do satisfy false @@ -99,7 +99,7 @@ it { is_expected.not_to be_satisfied } end - context "#satisfy with block returning true and without :build_env" do + describe "#satisfy with block returning true and without :build_env" do let(:klass) do Class.new(described_class) do satisfy do @@ -114,7 +114,7 @@ end end - context "#satisfy with block returning true and :build_env set to false" do + describe "#satisfy with block returning true and :build_env set to false" do let(:klass) do Class.new(described_class) do satisfy(build_env: false) do @@ -129,7 +129,7 @@ end end - context "#satisfy with block returning path and without :build_env" do + describe "#satisfy with block returning path and without :build_env" do let(:klass) do Class.new(described_class) do satisfy do @@ -153,7 +153,7 @@ it { is_expected.to be_a_build_requirement } end - context "#build omitted" do + describe "#build omitted" do it { is_expected.not_to be_a_build_requirement } end end
false
Other
Homebrew
brew
e88f6b9da9fab7dde364a8049b023b736b6ef002.json
args: Add passthrough method and tests
Library/Homebrew/cli/args.rb
@@ -21,16 +21,14 @@ def option_to_name(option) end def cli_args - return @cli_args unless @cli_args.nil? + return @cli_args if @cli_args @cli_args = [] processed_options.each do |short, long| option = long || short switch = "#{option_to_name(option)}?".to_sym flag = option_to_name(option).to_sym - if @table[switch].instance_of? TrueClass - @cli_args << option - elsif @table[flag].instance_of? TrueClass + if @table[switch] == true || @table[flag] == true @cli_args << option elsif @table[flag].instance_of? String @cli_args << option + "=" + @table[flag] @@ -48,6 +46,10 @@ def options_only def flags_only @flags_only ||= cli_args.select { |arg| arg.start_with?("--") } end + + def passthrough + options_only - CLI::Parser.global_options.values.map(&:first).flatten + end end end end
true
Other
Homebrew
brew
e88f6b9da9fab7dde364a8049b023b736b6ef002.json
args: Add passthrough method and tests
Library/Homebrew/cmd/cat.rb
@@ -25,7 +25,6 @@ def cat raise "`brew cat` doesn't support multiple arguments" if args.remaining.size > 1 cd HOMEBREW_REPOSITORY - cat_args = Homebrew.args.options_only - CLI::Parser.global_options.values.map(&:first).flatten - safe_system "cat", formulae.first.path, *cat_args + safe_system "cat", formulae.first.path, *Homebrew.args.passthrough end end
true
Other
Homebrew
brew
e88f6b9da9fab7dde364a8049b023b736b6ef002.json
args: Add passthrough method and tests
Library/Homebrew/cmd/list.rb
@@ -70,8 +70,7 @@ def list puts Formatter.columns(full_names) else ENV["CLICOLOR"] = nil - ls_args = Homebrew.args.options_only - CLI::Parser.global_options.values.map(&:first).flatten - safe_system "ls", *ls_args << HOMEBREW_CELLAR + safe_system "ls", *Homebrew.args.passthrough << HOMEBREW_CELLAR end elsif args.verbose? || !$stdout.tty? system_command! "find", args: ARGV.kegs.map(&:to_s) + %w[-not -type d -print], print_stdout: true
true
Other
Homebrew
brew
e88f6b9da9fab7dde364a8049b023b736b6ef002.json
args: Add passthrough method and tests
Library/Homebrew/test/cli/parser_spec.rb
@@ -230,5 +230,10 @@ parser.parse(["--foo", "--bar=value", "-v", "-s", "a", "b", "cdefg"]) expect(Homebrew.args.flags_only).to eq %w[--foo --bar=value --verbose] end + + it "#passthrough" do + parser.parse(["--foo", "--bar=value", "-v", "-s", "a", "b", "cdefg"]) + expect(Homebrew.args.passthrough).to eq %w[--foo --bar=value -s] + end end end
true
Other
Homebrew
brew
da19c15c101eb3ebecf5b01f9185dc6a92ae6f23.json
create: simplify conditional in template
Library/Homebrew/formula_creator.rb
@@ -150,7 +150,7 @@ def install "--prefix=\#{prefix}" # system "cmake", ".", *std_cmake_args <% end %> - <% if mode != :meson and mode != :go and mode != :python %> + <% if mode == :autotools or mode == :cmake %> system "make", "install" # if this fails, try separate make/make install steps <% end %> end
false
Other
Homebrew
brew
f6ef26a127fdcc2687004ffef198f519fd160cfd.json
Fix OS version logic for uses_from_macos
Library/Homebrew/extend/os/mac/software_spec.rb
@@ -23,9 +23,9 @@ def uses_from_macos(deps, **args) def add_mac_dependency?(args) args.each { |key, version| args[key] = OS::Mac::Version.from_symbol(version) } - return false if args[:after] && OS::Mac.version < args[:after] + return false if args[:after] && OS::Mac.version >= args[:after] - return false if args[:before] && OS::Mac.version >= args[:before] + return false if args[:before] && OS::Mac.version < args[:before] args.present? end
true
Other
Homebrew
brew
f6ef26a127fdcc2687004ffef198f519fd160cfd.json
Fix OS version logic for uses_from_macos
Library/Homebrew/test/os/mac/software_spec_spec.rb
@@ -13,43 +13,46 @@ allow(OS::Mac).to receive(:version).and_return(OS::Mac::Version.new(sierra_os_version)) end - it "allows specifying dependencies before certain version" do + it "allows specifying macOS dependencies before a certain version" do spec.uses_from_macos("foo", before: :high_sierra) - expect(spec.deps.first.name).to eq("foo") + expect(spec.deps).to be_empty + expect(spec.uses_from_macos_elements.first).to eq("foo") end - it "allows specifying dependencies after certain version" do + it "allows specifying macOS dependencies after a certain version" do spec.uses_from_macos("foo", after: :el_capitan) - expect(spec.deps.first.name).to eq("foo") + expect(spec.deps).to be_empty + expect(spec.uses_from_macos_elements.first).to eq("foo") end - it "doesn't adds a dependency if it doesn't meet OS version requirements" do + it "doesn't add a macOS dependency if the OS version doesn't meet requirements" do spec.uses_from_macos("foo", after: :high_sierra) spec.uses_from_macos("bar", before: :el_capitan) - expect(spec.deps).to be_empty + expect(spec.deps.first.name).to eq("foo") + expect(spec.uses_from_macos_elements).to be_empty end it "works with tags" do - spec.uses_from_macos("foo" => :head, :after => :el_capitan) + spec.uses_from_macos("foo" => :head, :after => :high_sierra) dep = spec.deps.first expect(dep.name).to eq("foo") expect(dep.tags).to include(:head) end - it "doesn't adds the dependency without OS version requirements" do + it "doesn't add a dependency if no OS version is specified" do spec.uses_from_macos("foo") spec.uses_from_macos("bar" => :head) expect(spec.deps).to be_empty end it "respects OS version requirements with tags" do - spec.uses_from_macos("foo" => :head, :after => :mojave) + spec.uses_from_macos("foo" => :head, :before => :mojave) expect(spec.deps).to be_empty end
true
Other
Homebrew
brew
9bd77b18197ecf5e3b4d048fb2452d7be474ee13.json
formula API: expose uses_from_macos list
Library/Homebrew/extend/os/mac/software_spec.rb
@@ -4,12 +4,18 @@ class SoftwareSpec undef uses_from_macos def uses_from_macos(deps, **args) + @uses_from_macos_elements ||= [] + if deps.is_a?(Hash) args = deps deps = Hash[*args.shift] end - depends_on(deps) if add_mac_dependency?(args) + if add_mac_dependency?(args) + depends_on(deps) + else + @uses_from_macos_elements << deps + end end private
true
Other
Homebrew
brew
9bd77b18197ecf5e3b4d048fb2452d7be474ee13.json
formula API: expose uses_from_macos list
Library/Homebrew/formula.rb
@@ -428,6 +428,9 @@ def aliases # The {Dependency}s for the currently active {SoftwareSpec}. delegate deps: :active_spec + # Dependencies provided by macOS for the currently active {SoftwareSpec}. + delegate uses_from_macos_elements: :active_spec + # The {Requirement}s for the currently active {SoftwareSpec}. delegate requirements: :active_spec @@ -1589,6 +1592,7 @@ def missing_dependencies(hide: nil) # @private def to_hash dependencies = deps + uses_from_macos = uses_from_macos_elements || [] hsh = { "name" => name, @@ -1624,6 +1628,7 @@ def to_hash "optional_dependencies" => dependencies.select(&:optional?) .map(&:name) .uniq, + "uses_from_macos" => uses_from_macos.uniq, "requirements" => [], "conflicts_with" => conflicts.map(&:name), "caveats" => caveats&.gsub(HOMEBREW_PREFIX, "$(brew --prefix)"),
true
Other
Homebrew
brew
9bd77b18197ecf5e3b4d048fb2452d7be474ee13.json
formula API: expose uses_from_macos list
Library/Homebrew/software_spec.rb
@@ -26,6 +26,7 @@ class SoftwareSpec attr_reader :dependency_collector attr_reader :bottle_specification attr_reader :compiler_failures + attr_reader :uses_from_macos_elements def_delegators :@resource, :stage, :fetch, :verify_download_integrity, :source_modified_time def_delegators :@resource, :download_name, :cached_download, :clear_cache
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/.rubocop_cask.yml
@@ -3,6 +3,8 @@ inherit_from: ./.rubocop_shared.yml Cask/HomepageMatchesUrl: Description: 'Ensure that the homepage and url match, otherwise add a comment. More info at https://github.com/Homebrew/homebrew-cask/blob/master/doc/cask_language_reference/stanzas/url.md#when-url-and-homepage-hostnames-differ-add-a-comment' Enabled: true + Exclude: + - '**/test/support/fixtures/cask/Casks/**/*.rb' Cask/HomepageUrlTrailingSlash: Description: 'Ensure that the homepage url has a slash after the domain name.'
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/cask/cmd/style.rb
@@ -31,7 +31,7 @@ def install_rubocop def cask_paths @cask_paths ||= if args.empty? - Tap.map(&:cask_dir).select(&:directory?) + Tap.map(&:cask_dir).select(&:directory?).concat(test_cask_paths) elsif args.any? { |file| File.exist?(file) } args.map { |path| Pathname(path).expand_path } else @@ -51,6 +51,13 @@ def default_args ] end + def test_cask_paths + [ + Pathname.new("#{HOMEBREW_LIBRARY}/Homebrew/test/support/fixtures/cask/Casks"), + Pathname.new("#{HOMEBREW_LIBRARY}/Homebrew/test/support/fixtures/third-party/Casks"), + ] + end + def normal_args default_args + ["--parallel"] end
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/cask/cmd/home_spec.rb
@@ -10,13 +10,13 @@ it_behaves_like "a command that handles invalid options" it "opens the homepage for the specified Cask" do - expect(described_class).to receive(:open_url).with("https://brew.sh") + expect(described_class).to receive(:open_url).with("https://brew.sh/") described_class.run("local-caffeine") end it "works for multiple Casks" do - expect(described_class).to receive(:open_url).with("https://brew.sh") - expect(described_class).to receive(:open_url).with("https://brew.sh") + expect(described_class).to receive(:open_url).with("https://brew.sh/") + expect(described_class).to receive(:open_url).with("https://brew.sh/") described_class.run("local-caffeine", "local-transmission") end
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/cask/cmd/info_spec.rb
@@ -12,7 +12,7 @@ described_class.run("local-caffeine") }.to output(<<~EOS).to_stdout local-caffeine: 1.2.3 - https://brew.sh + https://brew.sh/ Not installed From: https://github.com/Homebrew/homebrew-cask/blob/master/Casks/local-caffeine.rb ==> Name @@ -41,7 +41,7 @@ let(:expected_output) { <<~EOS local-caffeine: 1.2.3 - https://brew.sh + https://brew.sh/ Not installed From: https://github.com/Homebrew/homebrew-cask/blob/master/Casks/local-caffeine.rb ==> Name @@ -50,7 +50,7 @@ Caffeine.app (App) local-transmission: 2.61 - https://brew.sh + https://brew.sh/ Not installed From: https://github.com/Homebrew/homebrew-cask/blob/master/Casks/local-transmission.rb ==> Name @@ -72,7 +72,7 @@ described_class.run("with-caveats") }.to output(<<~EOS).to_stdout with-caveats: 1.2.3 - https://brew.sh + https://brew.sh/ Not installed From: https://github.com/Homebrew/homebrew-cask/blob/master/Casks/with-caveats.rb ==> Name @@ -97,7 +97,7 @@ described_class.run("with-conditional-caveats") }.to output(<<~EOS).to_stdout with-conditional-caveats: 1.2.3 - https://brew.sh + https://brew.sh/ Not installed From: https://github.com/Homebrew/homebrew-cask/blob/master/Casks/with-conditional-caveats.rb ==> Name @@ -112,7 +112,7 @@ described_class.run("with-languages") }.to output(<<~EOS).to_stdout with-languages: 1.2.3 - https://brew.sh + https://brew.sh/ Not installed From: https://github.com/Homebrew/homebrew-cask/blob/master/Casks/with-languages.rb ==> Name @@ -129,7 +129,7 @@ described_class.run("without-languages") }.to output(<<~EOS).to_stdout without-languages: 1.2.3 - https://brew.sh + https://brew.sh/ Not installed From: https://github.com/Homebrew/homebrew-cask/blob/master/Casks/without-languages.rb ==> Name
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/cask/cmd/internal_stanza_spec.rb
@@ -5,7 +5,7 @@ command = described_class.new("homepage", "local-caffeine") expect { command.run - }.to output("https://brew.sh\n").to_stdout + }.to output("https://brew.sh/\n").to_stdout end it "raises an exception when stanza is unknown/unsupported" do
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/cask/cmd/style_spec.rb
@@ -80,8 +80,12 @@ end it { - expect(subject).to contain_exactly(a_path_ending_with("/homebrew/homebrew-cask/Casks"), - a_path_ending_with("/third-party/homebrew-tap/Casks")) + expect(subject).to contain_exactly( + a_path_ending_with("/homebrew/homebrew-cask/Casks"), + a_path_ending_with("/third-party/homebrew-tap/Casks"), + a_path_ending_with("/Homebrew/test/support/fixtures/cask/Casks"), + a_path_ending_with("/Homebrew/test/support/fixtures/third-party/Casks"), + ) } end
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/bad-checksum.rb
@@ -3,7 +3,7 @@ sha256 'badbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadb' url "file://#{TEST_FIXTURE_DIR}/cask/caffeine.zip" - homepage 'https://brew.sh' + homepage 'https://brew.sh/' app 'Caffeine.app' end
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/booby-trap.rb
@@ -3,6 +3,6 @@ url do # to be lazily evaluated - fail 'Boom' + raise 'Boom' end end
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/installer-with-uninstall.rb
@@ -3,7 +3,7 @@ sha256 '67cdb8a02803ef37fdbf7e0be205863172e41a561ca446cd84f0d7ab35a99d94' url "file://#{TEST_FIXTURE_DIR}/cask/caffeine.zip" - homepage 'https://brew.sh' + homepage 'https://brew.sh/' installer manual: 'Caffeine.app'
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/invalid/invalid-header-format.rb
@@ -1,9 +1,9 @@ -cask => 'invalid-header-format' do +cask 'invalid-header-format', :invalid do version '1.2.3' sha256 '67cdb8a02803ef37fdbf7e0be205863172e41a561ca446cd84f0d7ab35a99d94' url "file://#{TEST_FIXTURE_DIR}/cask/caffeine.zip" - homepage 'https://brew.sh' + homepage 'https://brew.sh/' app 'Caffeine.app' end
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/invalid/invalid-header-token-mismatch.rb
@@ -3,7 +3,7 @@ sha256 '67cdb8a02803ef37fdbf7e0be205863172e41a561ca446cd84f0d7ab35a99d94' url "file://#{TEST_FIXTURE_DIR}/cask/caffeine.zip" - homepage 'https://brew.sh' + homepage 'https://brew.sh/' app 'Caffeine.app' end
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/invalid/invalid-header-version.rb
@@ -3,7 +3,7 @@ sha256 '67cdb8a02803ef37fdbf7e0be205863172e41a561ca446cd84f0d7ab35a99d94' url "file://#{TEST_FIXTURE_DIR}/cask/caffeine.zip" - homepage 'https://brew.sh' + homepage 'https://brew.sh/' app 'Caffeine.app' end
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/invalid/invalid-two-homepage.rb
@@ -3,7 +3,7 @@ sha256 '67cdb8a02803ef37fdbf7e0be205863172e41a561ca446cd84f0d7ab35a99d94' url "file://#{TEST_FIXTURE_DIR}/cask/caffeine.zip" - homepage 'https://brew.sh' + homepage 'https://brew.sh/' homepage 'https://www.brew.sh/local-caffeine' app 'Caffeine.app'
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/invalid/invalid-two-url.rb
@@ -4,7 +4,7 @@ url "file://#{TEST_FIXTURE_DIR}/cask/caffeine.zip" url 'https://brew.sh/caffeine.zip' - homepage 'https://brew.sh' + homepage 'https://brew.sh/' app 'Caffeine.app' end
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/invalid/invalid-two-version.rb
@@ -4,7 +4,7 @@ sha256 '67cdb8a02803ef37fdbf7e0be205863172e41a561ca446cd84f0d7ab35a99d94' url "file://#{TEST_FIXTURE_DIR}/cask/caffeine.zip" - homepage 'https://brew.sh' + homepage 'https://brew.sh/' app 'Caffeine.app' end
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/local-caffeine.rb
@@ -3,7 +3,7 @@ sha256 '67cdb8a02803ef37fdbf7e0be205863172e41a561ca446cd84f0d7ab35a99d94' url "file://#{TEST_FIXTURE_DIR}/cask/caffeine.zip" - homepage 'https://brew.sh' + homepage 'https://brew.sh/' app 'Caffeine.app' end
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/local-transmission.rb
@@ -1,10 +1,10 @@ cask 'local-transmission' do - name 'Transmission' version '2.61' sha256 'e44ffa103fbf83f55c8d0b1bea309a43b2880798dae8620b1ee8da5e1095ec68' url "file://#{TEST_FIXTURE_DIR}/cask/transmission-2.61.dmg" - homepage 'https://brew.sh' + name 'Transmission' + homepage 'https://brew.sh/' app 'Transmission.app' end
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/missing-checksum.rb
@@ -2,7 +2,7 @@ version '1.2.3' url "file://#{TEST_FIXTURE_DIR}/cask/caffeine.zip" - homepage 'https://brew.sh' + homepage 'https://brew.sh/' app 'Caffeine.app' end
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/missing-url.rb
@@ -1,5 +1,5 @@ cask 'missing-url' do version '1.2.3' - homepage 'https://brew.sh' + homepage 'https://brew.sh/' end
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/missing-version.rb
@@ -1,4 +1,4 @@ cask 'missing-version' do - url 'https://localhost/something.dmg' - homepage 'https://brew.sh' + url 'https://brew.sh/TestCask.dmg' + homepage 'https://brew.sh/' end
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/no-checksum.rb
@@ -3,7 +3,7 @@ sha256 :no_check url "file://#{TEST_FIXTURE_DIR}/cask/caffeine.zip" - homepage 'https://brew.sh' + homepage 'https://brew.sh/' app 'Caffeine.app' end
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/outdated/bad-checksum.rb
@@ -3,7 +3,7 @@ sha256 '67cdb8a02803ef37fdbf7e0be205863172e41a561ca446cd84f0d7ab35a99d94' url "file://#{TEST_FIXTURE_DIR}/cask/caffeine.zip" - homepage 'https://brew.sh' + homepage 'https://brew.sh/' app 'Caffeine.app' end
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/outdated/local-caffeine.rb
@@ -3,7 +3,7 @@ sha256 '67cdb8a02803ef37fdbf7e0be205863172e41a561ca446cd84f0d7ab35a99d94' url "file://#{TEST_FIXTURE_DIR}/cask/caffeine.zip" - homepage 'https://brew.sh' + homepage 'https://brew.sh/' app 'Caffeine.app' end
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/outdated/local-transmission.rb
@@ -3,7 +3,7 @@ sha256 'e44ffa103fbf83f55c8d0b1bea309a43b2880798dae8620b1ee8da5e1095ec68' url "file://#{TEST_FIXTURE_DIR}/cask/transmission-2.61.dmg" - homepage 'https://brew.sh' + homepage 'https://brew.sh/' app 'Transmission.app' end
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/outdated/version-latest.rb
@@ -3,7 +3,7 @@ sha256 :no_check url "file://#{TEST_FIXTURE_DIR}/cask/caffeines.zip" - homepage 'https://brew.sh' + homepage 'https://brew.sh/' app 'Caffeine Mini.app' app 'Caffeine Pro.app'
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/version-latest.rb
@@ -3,7 +3,7 @@ sha256 :no_check url "file://#{TEST_FIXTURE_DIR}/cask/caffeines.zip" - homepage 'https://brew.sh' + homepage 'https://brew.sh/' app 'Caffeine Mini.app' app 'Caffeine Pro.app'
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/will-fail-if-upgraded.rb
@@ -3,7 +3,7 @@ sha256 'e44ffa103fbf83f55c8d0b1bea309a43b2880798dae8620b1ee8da5e1095ec68' url "file://#{TEST_FIXTURE_DIR}/cask/transmission-2.61.dmg" - homepage 'https://brew.sh' + homepage 'https://brew.sh/' app 'container' end
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/with-alt-target.rb
@@ -3,7 +3,7 @@ sha256 '67cdb8a02803ef37fdbf7e0be205863172e41a561ca446cd84f0d7ab35a99d94' url "file://#{TEST_FIXTURE_DIR}/cask/caffeine.zip" - homepage 'https://brew.sh' + homepage 'https://brew.sh/' app 'Caffeine.app', target: 'AnotherName.app' end
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/with-caveats.rb
@@ -3,7 +3,7 @@ sha256 '67cdb8a02803ef37fdbf7e0be205863172e41a561ca446cd84f0d7ab35a99d94' url "file://#{TEST_FIXTURE_DIR}/cask/caffeine.zip" - homepage 'https://brew.sh' + homepage 'https://brew.sh/' app 'Caffeine.app'
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/with-conditional-caveats.rb
@@ -3,12 +3,12 @@ sha256 '67cdb8a02803ef37fdbf7e0be205863172e41a561ca446cd84f0d7ab35a99d94' url "file://#{TEST_FIXTURE_DIR}/cask/caffeine.zip" - homepage 'https://brew.sh' + homepage 'https://brew.sh/' app 'Caffeine.app' # a do block may print and use a DSL caveats do - puts 'This caveat is conditional' if false # rubocop:disable Lint/LiteralInCondition + puts 'This caveat is conditional' if false # rubocop:disable Lint/LiteralAsCondition end end
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/with-installable.rb
@@ -7,7 +7,7 @@ pkg 'MyFancyPkg/Fancy.pkg' - uninstall script: { executable: 'MyFancyPkg/FancyUninstaller.tool', args: %w[--please] }, + uninstall script: { executable: 'MyFancyPkg/FancyUninstaller.tool', args: ['--please'] }, quit: 'my.fancy.package.app', login_item: 'Fancy', delete: [
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/with-installer-manual.rb
@@ -3,7 +3,7 @@ sha256 '67cdb8a02803ef37fdbf7e0be205863172e41a561ca446cd84f0d7ab35a99d94' url "file://#{TEST_FIXTURE_DIR}/cask/caffeine.zip" - homepage 'https://brew.sh' + homepage 'https://brew.sh/' installer manual: 'Caffeine.app' end
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/with-languages.rb
@@ -1,18 +1,18 @@ cask 'with-languages' do version '1.2.3' - language "zh" do - sha256 "abc123" - "zh-CN" + language 'zh' do + sha256 'abc123' + 'zh-CN' end - language "en-US", default: true do - sha256 "xyz789" - "en-US" + language 'en-US', default: true do + sha256 'xyz789' + 'en-US' end url "file://#{TEST_FIXTURE_DIR}/cask/caffeine.zip" - homepage 'https://brew.sh' + homepage 'https://brew.sh/' app 'Caffeine.app' end
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/with-non-executable-binary.rb
@@ -5,5 +5,5 @@ url "file://#{TEST_FIXTURE_DIR}/cask/naked_non_executable" homepage 'https://brew.sh/with-binary' - binary "naked_non_executable" + binary 'naked_non_executable' end
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/with-postflight-multi.rb
@@ -9,7 +9,6 @@ postflight do end - postflight do end end
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/with-preflight-multi.rb
@@ -9,7 +9,6 @@ preflight do end - preflight do end end
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/with-two-apps-correct.rb
@@ -3,7 +3,7 @@ sha256 '3178fbfd1ea5d87a2a0662a4eb599ebc9a03888e73f37538d9f3f6ee69d2368e' url "file://#{TEST_FIXTURE_DIR}/cask/caffeines.zip" - homepage 'https://brew.sh' + homepage 'https://brew.sh/' app 'Caffeine Mini.app' app 'Caffeine Pro.app'
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/with-two-apps-subdir.rb
@@ -3,7 +3,7 @@ sha256 'd687c22a21c02bd8f07da9302c8292b93a04df9a929e3f04d09aea6c76f75c65' url "file://#{TEST_FIXTURE_DIR}/cask/caffeines-subdir.zip" - homepage 'https://brew.sh' + homepage 'https://brew.sh/' app 'Caffeines/Caffeine Mini.app' app 'Caffeines/Caffeine Pro.app'
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/with-uninstall-early-script.rb
@@ -7,5 +7,5 @@ pkg 'MyFancyPkg/Fancy.pkg' - uninstall early_script: { executable: 'MyFancyPkg/FancyUninstaller.tool', args: %w[--please] } + uninstall early_script: { executable: 'MyFancyPkg/FancyUninstaller.tool', args: ['--please'] } end
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/with-uninstall-multi.rb
@@ -8,6 +8,5 @@ pkg 'MyFancyPkg/Fancy.pkg' uninstall rmdir: "#{TEST_TMPDIR}/empty_directory_path" - uninstall delete: "#{TEST_TMPDIR}/empty_directory_path" end
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/with-uninstall-postflight-multi.rb
@@ -9,7 +9,6 @@ uninstall_postflight do end - uninstall_postflight do end end
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/with-uninstall-preflight-multi.rb
@@ -9,7 +9,6 @@ uninstall_preflight do end - uninstall_preflight do end end
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/with-uninstall-script-app.rb
@@ -16,6 +16,6 @@ uninstall script: { executable: "#{appdir}/MyFancyApp.app/uninstall.sh", - sudo: false + sudo: false, } end
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/with-uninstall-script.rb
@@ -7,5 +7,5 @@ pkg 'MyFancyPkg/Fancy.pkg' - uninstall script: { executable: 'MyFancyPkg/FancyUninstaller.tool', args: %w[--please] } + uninstall script: { executable: 'MyFancyPkg/FancyUninstaller.tool', args: ['--please'] } end
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/with-zap-early-script.rb
@@ -7,5 +7,5 @@ pkg 'MyFancyPkg/Fancy.pkg' - zap early_script: { executable: 'MyFancyPkg/FancyUninstaller.tool', args: %w[--please] } + zap early_script: { executable: 'MyFancyPkg/FancyUninstaller.tool', args: ['--please'] } end
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/with-zap-multi.rb
@@ -8,6 +8,5 @@ pkg 'MyFancyPkg/Fancy.pkg' zap rmdir: "#{TEST_TMPDIR}/empty_directory_path" - zap delete: "#{TEST_TMPDIR}/empty_directory_path" end
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/with-zap-script.rb
@@ -7,5 +7,5 @@ pkg 'MyFancyPkg/Fancy.pkg' - zap script: { executable: 'MyFancyPkg/FancyUninstaller.tool', args: %w[--please] } + zap script: { executable: 'MyFancyPkg/FancyUninstaller.tool', args: ['--please'] } end
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/with-zap.rb
@@ -11,7 +11,7 @@ zap script: { executable: 'MyFancyPkg/FancyUninstaller.tool', - args: %w[--please], + args: ['--please'], }, quit: 'my.fancy.package.app', login_item: 'Fancy',
true
Other
Homebrew
brew
45806f6a9799b25ec256b3512ea965dc07c5cd9d.json
Include test casks in the cask style check. Currently the tests casks found in "/Homebrew/test/support/fixtures/cask/Casks" and "/Homebrew/test/support/fixtures/third-party/Casks" aren't included in the paths checked when running "brew cask style". This change includes these test cask paths in the checked paths, and also includes the auto style fixes made by running `brew cask style --fix`.
Library/Homebrew/test/support/fixtures/cask/Casks/without-languages.rb
@@ -3,7 +3,7 @@ sha256 '67cdb8a02803ef37fdbf7e0be205863172e41a561ca446cd84f0d7ab35a99d94' url "file://#{TEST_FIXTURE_DIR}/cask/caffeine.zip" - homepage 'https://brew.sh' + homepage 'https://brew.sh/' app 'Caffeine.app' end
true
Other
Homebrew
brew
c9a75db27d36dcf3a8fa85590e7e3c0b61de3862.json
cask: recommend adoptopenjdk as per #6040
Library/Homebrew/cask/dsl/caveats.rb
@@ -87,17 +87,17 @@ def eval_caveats(&block) if java_version == :any <<~EOS #{@cask} requires Java. You can install the latest version with: - brew cask install java + brew cask install adoptopenjdk EOS elsif java_version.include?("11") || java_version.include?("+") <<~EOS #{@cask} requires Java #{java_version}. You can install the latest version with: - brew cask install java + brew cask install adoptopenjdk EOS else <<~EOS #{@cask} requires Java #{java_version}. You can install it with: - brew cask install homebrew/cask-versions/java#{java_version} + brew cask install homebrew/cask-versions/adoptopenjdk#{java_version} EOS end end
false
Other
Homebrew
brew
a9b9d4613decfca219ba07b752e7ef1df58f72c3.json
cask: return nil instead of "" if no caveats
Library/Homebrew/cask/cask.rb
@@ -147,7 +147,7 @@ def to_h "version" => version, "sha256" => sha256, "artifacts" => artifacts.map(&method(:to_h_gsubs)), - "caveats" => to_h_string_gsubs(caveats), + "caveats" => (to_h_string_gsubs(caveats) unless caveats.empty?), "depends_on" => depends_on, "conflicts_with" => conflicts_with, "container" => container,
false
Other
Homebrew
brew
fbc13f05dd67656915c320cf33201f75af2d60ba.json
utils/curl: extract status checks into method.
Library/Homebrew/utils/curl.rb
@@ -94,7 +94,7 @@ def curl_check_http_content(url, user_agents: [:default], check_content: false, user_agents.each do |ua| details = curl_http_content_headers_and_checksum(url, hash_needed: hash_needed, user_agent: ua) user_agent = ua - break if (100..299).include?(details[:status].to_i) + break if http_status_ok?(details[:status]) end unless details[:status] @@ -104,7 +104,7 @@ def curl_check_http_content(url, user_agents: [:default], check_content: false, return "The URL #{url} is not reachable" end - unless (100..299).include?(details[:status].to_i) + unless http_status_ok?(details[:status]) return "The URL #{url} is not reachable (HTTP status code #{details[:status]})" end @@ -119,8 +119,8 @@ def curl_check_http_content(url, user_agents: [:default], check_content: false, secure_details = curl_http_content_headers_and_checksum(secure_url, hash_needed: true, user_agent: user_agent) - if !(100..299).include?(details[:status].to_i) || - !(100..299).include?(secure_details[:status].to_i) + if !http_status_ok?(details[:status]) || + !http_status_ok?(secure_details[:status]) return end @@ -192,3 +192,7 @@ def curl_http_content_headers_and_checksum(url, hash_needed: false, user_agent: file: output, } end + +def http_status_ok?(status) + (100..299).cover?(status.to_i) +end
false
Other
Homebrew
brew
af10d13381bb89045a1359a5b8c6274189f5f542.json
Check blacklisted Casks when auditing. In some cases, certain Casks shouldn't be resubmitted for specific reasons: difficult to maintain, developers maintain their own version, ... To make sure these cases are restricted - we can add them to a blacklist and have the blacklist checked as part of the `brew cask audit` steps.
Library/Homebrew/cask/audit.rb
@@ -1,5 +1,6 @@ # frozen_string_literal: true +require "cask/blacklist" require "cask/checkable" require "cask/download" require "digest" @@ -30,6 +31,7 @@ def check_token_conflicts? end def run! + check_blacklist check_required_stanzas check_version check_sha256 @@ -320,6 +322,13 @@ def check_appcast_contains_version add_error "appcast at URL '#{appcast_stanza}' offline or looping" end + def check_blacklist + return if cask.tap&.user != "Homebrew" + return unless reason = Blacklist.blacklisted_reason(cask.token) + + add_error "#{cask.token} is blacklisted: #{reason}" + end + def check_https_availability return unless download
true
Other
Homebrew
brew
af10d13381bb89045a1359a5b8c6274189f5f542.json
Check blacklisted Casks when auditing. In some cases, certain Casks shouldn't be resubmitted for specific reasons: difficult to maintain, developers maintain their own version, ... To make sure these cases are restricted - we can add them to a blacklist and have the blacklist checked as part of the `brew cask audit` steps.
Library/Homebrew/cask/blacklist.rb
@@ -0,0 +1,16 @@ +# frozen_string_literal: true + +module Cask + module Blacklist + def self.blacklisted_reason(name) + case name + when /^adobe\-(after|illustrator|indesign|photoshop|premiere)/ + "Adobe casks were removed because they are too difficult to maintain." + when /^audacity$/ + "Audacity was removed because it is too difficult to download programmatically." + when /^pharo$/ + "Pharo developers maintain their own tap." + end + end + end +end
true
Other
Homebrew
brew
af10d13381bb89045a1359a5b8c6274189f5f542.json
Check blacklisted Casks when auditing. In some cases, certain Casks shouldn't be resubmitted for specific reasons: difficult to maintain, developers maintain their own version, ... To make sure these cases are restricted - we can add them to a blacklist and have the blacklist checked as part of the `brew cask audit` steps.
Library/Homebrew/test/cask/audit_spec.rb
@@ -399,6 +399,28 @@ def include_msg?(messages, msg) end end + describe "blacklist checks" do + context "when the Cask isn't blacklisted" do + let(:cask_token) { "adobe-air" } + + it { is_expected.to pass } + end + + context "when the Cask is blacklisted" do + context "and it's in the official Homebrew tap" do + let(:cask_token) { "adobe-illustrator" } + + it { is_expected.to fail_with(/#{cask_token} is blacklisted: \w+/) } + end + + context "and it isn't in the official Homebrew tap" do + let(:cask_token) { "pharo" } + + it { is_expected.to pass } + end + end + end + describe "latest with auto_updates checks" do let(:warning_msg) { "Casks with `version :latest` should not use `auto_updates`" } @@ -541,8 +563,8 @@ def include_msg?(messages, msg) context "when an exception is raised" do let(:cask) { instance_double(Cask::Cask) } - it "does not fail" do - expect(cask).to receive(:version).and_raise(StandardError.new) + it "fails the audit" do + expect(cask).to receive(:tap).and_raise(StandardError.new) expect(subject).to fail_with(/exception while auditing/) end end
true
Other
Homebrew
brew
af10d13381bb89045a1359a5b8c6274189f5f542.json
Check blacklisted Casks when auditing. In some cases, certain Casks shouldn't be resubmitted for specific reasons: difficult to maintain, developers maintain their own version, ... To make sure these cases are restricted - we can add them to a blacklist and have the blacklist checked as part of the `brew cask audit` steps.
Library/Homebrew/test/cask/blacklist_spec.rb
@@ -0,0 +1,21 @@ +# frozen_string_literal: true + +describe Cask::Blacklist, :cask do + describe "::blacklisted_reason" do + matcher :blacklist do |name| + match do |expected| + expected.blacklisted_reason(name) + end + end + + it { is_expected.not_to blacklist("adobe-air") } + it { is_expected.to blacklist("adobe-after-effects") } + it { is_expected.to blacklist("adobe-illustrator") } + it { is_expected.to blacklist("adobe-indesign") } + it { is_expected.to blacklist("adobe-photoshop") } + it { is_expected.to blacklist("adobe-premiere") } + it { is_expected.to blacklist("audacity") } + it { is_expected.to blacklist("pharo") } + it { is_expected.not_to blacklist("non-blacklisted-cask") } + end +end
true
Other
Homebrew
brew
af10d13381bb89045a1359a5b8c6274189f5f542.json
Check blacklisted Casks when auditing. In some cases, certain Casks shouldn't be resubmitted for specific reasons: difficult to maintain, developers maintain their own version, ... To make sure these cases are restricted - we can add them to a blacklist and have the blacklist checked as part of the `brew cask audit` steps.
Library/Homebrew/test/support/fixtures/cask/Casks/adobe-air.rb
@@ -0,0 +1,10 @@ +cask 'adobe-air' do + version '1.2.3' + sha256 '8c62a2b791cf5f0da6066a0a4b6e85f62949cd60975da062df44adf887f4370b' + + url 'https://brew.sh/TestCask.dmg' + name 'Adobe Air' + homepage 'https://brew.sh/' + + app 'TestCask.app' +end
true
Other
Homebrew
brew
af10d13381bb89045a1359a5b8c6274189f5f542.json
Check blacklisted Casks when auditing. In some cases, certain Casks shouldn't be resubmitted for specific reasons: difficult to maintain, developers maintain their own version, ... To make sure these cases are restricted - we can add them to a blacklist and have the blacklist checked as part of the `brew cask audit` steps.
Library/Homebrew/test/support/fixtures/cask/Casks/adobe-illustrator.rb
@@ -0,0 +1,10 @@ +cask 'adobe-illustrator' do + version '1.2.3' + sha256 '8c62a2b791cf5f0da6066a0a4b6e85f62949cd60975da062df44adf887f4370b' + + url 'https://brew.sh/TestCask.dmg' + name 'Adobe Illustrator' + homepage 'https://brew.sh/' + + app 'TestCask.app' +end
true
Other
Homebrew
brew
af10d13381bb89045a1359a5b8c6274189f5f542.json
Check blacklisted Casks when auditing. In some cases, certain Casks shouldn't be resubmitted for specific reasons: difficult to maintain, developers maintain their own version, ... To make sure these cases are restricted - we can add them to a blacklist and have the blacklist checked as part of the `brew cask audit` steps.
Library/Homebrew/test/support/fixtures/third-party/Casks/pharo.rb
@@ -0,0 +1,10 @@ +cask 'pharo' do + version '1.2.3' + sha256 '8c62a2b791cf5f0da6066a0a4b6e85f62949cd60975da062df44adf887f4370b' + + url 'https://brew.sh/ThirdParty.dmg' + name 'Pharo' + homepage 'https://brew.sh/' + + app 'ThirdParty.app' +end
true
Other
Homebrew
brew
23294a5647dc565b12700a36cc90dc5f38ccc2e9.json
Docs: Add a link to the linuxbrew-core maintainer guide
docs/README.md
@@ -47,6 +47,7 @@ - [New Maintainer Checklist](New-Maintainer-Checklist.md) - [Maintainers: Avoiding Burnout](Maintainers-Avoiding-Burnout.md) - [Maintainer Guidelines](Maintainer-Guidelines.md) +- [Homebrew/linuxbrew-core Maintainer Guide](Homebrew-linuxbrew-core-Maintainer-Guide.md) - [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)
false