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 | 7be216fcbec3021df87fb37b17bbbd91202af6f5.json | change function name | Library/Homebrew/dev-cmd/audit.rb | @@ -123,7 +123,7 @@ def audit
elsif args.no_named?
[Formula, Cask::Cask.to_a]
else
- args.named.to_formulae_and_casks(only: args.only_path_formula_or_cask)
+ args.named.to_formulae_and_casks(only: args.only_formula_or_cask)
.partition { |formula_or_cask| formula_or_cask.is_a?(Formu... | true |
Other | Homebrew | brew | 7be216fcbec3021df87fb37b17bbbd91202af6f5.json | change function name | Library/Homebrew/dev-cmd/cat.rb | @@ -38,6 +38,6 @@ def cat
"cat"
end
- safe_system pager, args.named.to_paths(only: args.only_path_formula_or_cask).first
+ safe_system pager, args.named.to_paths(only: args.only_formula_or_cask).first
end
end | true |
Other | Homebrew | brew | 7be216fcbec3021df87fb37b17bbbd91202af6f5.json | change function name | Library/Homebrew/dev-cmd/edit.rb | @@ -39,7 +39,7 @@ def edit
EOS
end
- paths = args.named.to_paths(only: args.only_path_formula_or_cask).select do |path|
+ paths = args.named.to_paths(only: args.only_formula_or_cask).select do |path|
next path if path.exist?
raise UsageError, "#{path} doesn't exist on disk. " \ | true |
Other | Homebrew | brew | d7f9bb6247f92b5ce7f4243ec1bee2cd3e1a9bab.json | add function to define path | Library/Homebrew/cli/args.rb | @@ -133,6 +133,11 @@ def context
Context::ContextStruct.new(debug: debug?, quiet: quiet?, verbose: verbose?)
end
+ def only_path_formula_or_cask
+ return :formula if formula? && !cask?
+ return :cask if cask? && !formula?
+ end
+
private
def option_to_name(optio... | true |
Other | Homebrew | brew | d7f9bb6247f92b5ce7f4243ec1bee2cd3e1a9bab.json | add function to define path | Library/Homebrew/cmd/fetch.rb | @@ -69,9 +69,6 @@ def fetch_args
def fetch
args = fetch_args.parse
- only = :formula if args.formula? && !args.cask?
- only = :cask if args.cask? && !args.formula?
-
bucket = if args.deps?
args.named.to_formulae_and_casks.flat_map do |formula_or_cask|
case formula_or_cask
@@ -84,7 +... | true |
Other | Homebrew | brew | d7f9bb6247f92b5ce7f4243ec1bee2cd3e1a9bab.json | add function to define path | Library/Homebrew/cmd/home.rb | @@ -35,9 +35,7 @@ def home
return
end
- only = :formula if args.formula? && !args.cask?
- only = :cask if args.cask? && !args.formula?
- homepages = args.named.to_formulae_and_casks(only: only).map do |formula_or_cask|
+ homepages = args.named.to_formulae_and_casks(only: args.only_path_formula... | true |
Other | Homebrew | brew | d7f9bb6247f92b5ce7f4243ec1bee2cd3e1a9bab.json | add function to define path | Library/Homebrew/cmd/info.rb | @@ -75,9 +75,6 @@ def info_args
def info
args = info_args.parse
- only = :formula if args.formula? && !args.cask?
- only = :cask if args.cask? && !args.formula?
-
if args.analytics?
if args.days.present? && VALID_DAYS.exclude?(args.days)
raise UsageError, "--days must be one of #{VA... | true |
Other | Homebrew | brew | d7f9bb6247f92b5ce7f4243ec1bee2cd3e1a9bab.json | add function to define path | Library/Homebrew/cmd/install.rb | @@ -131,9 +131,6 @@ def install_args
def install
args = install_args.parse
- only = :formula if args.formula? && !args.cask?
- only = :cask if args.cask? && !args.formula?
-
args.named.each do |name|
next if File.exist?(name)
next if name !~ HOMEBREW_TAP_FORMULA_REGEX && name !~ HOMEB... | true |
Other | Homebrew | brew | d7f9bb6247f92b5ce7f4243ec1bee2cd3e1a9bab.json | add function to define path | Library/Homebrew/cmd/uninstall.rb | @@ -47,10 +47,12 @@ def uninstall_args
def uninstall
args = uninstall_args.parse
- only = :formula if args.formula? && !args.cask?
- only = :cask if args.cask? && !args.formula?
+ all_kegs, casks = args.named.to_kegs_to_casks(
+ only: args.only_path_formula_or_cask,
+ ignore_u... | true |
Other | Homebrew | brew | d7f9bb6247f92b5ce7f4243ec1bee2cd3e1a9bab.json | add function to define path | Library/Homebrew/cmd/upgrade.rb | @@ -95,10 +95,7 @@ def upgrade_args
def upgrade
args = upgrade_args.parse
- only = :formula if args.formula? && !args.cask?
- only = :cask if args.cask? && !args.formula?
-
- formulae, casks = args.named.to_resolved_formulae_to_casks(only: only)
+ formulae, casks = args.named.to_resolved_formulae_... | true |
Other | Homebrew | brew | d7f9bb6247f92b5ce7f4243ec1bee2cd3e1a9bab.json | add function to define path | Library/Homebrew/dev-cmd/audit.rb | @@ -110,9 +110,6 @@ def audit
git = args.git?
skip_style = args.skip_style? || args.no_named? || args.tap
- only = :formula if args.formula? && !args.cask?
- only = :cask if args.cask? && !args.formula?
-
ENV.activate_extensions!
ENV.setup_build_environment
@@ -126,7 +123,7 @@ def audit
... | true |
Other | Homebrew | brew | d7f9bb6247f92b5ce7f4243ec1bee2cd3e1a9bab.json | add function to define path | Library/Homebrew/dev-cmd/cat.rb | @@ -30,9 +30,6 @@ def cat_args
def cat
args = cat_args.parse
- only = :formula if args.formula? && !args.cask?
- only = :cask if args.cask? && !args.formula?
-
cd HOMEBREW_REPOSITORY
pager = if Homebrew::EnvConfig.bat?
ENV["BAT_CONFIG_PATH"] = Homebrew::EnvConfig.bat_config_path
@@ -41,... | true |
Other | Homebrew | brew | d7f9bb6247f92b5ce7f4243ec1bee2cd3e1a9bab.json | add function to define path | Library/Homebrew/dev-cmd/edit.rb | @@ -31,9 +31,6 @@ def edit_args
def edit
args = edit_args.parse
- only = :formula if args.formula? && !args.cask?
- only = :cask if args.cask? && !args.formula?
-
unless (HOMEBREW_REPOSITORY/".git").directory?
raise <<~EOS
Changes will be lost!
@@ -42,7 +39,7 @@ def edit
EOS
... | true |
Other | Homebrew | brew | 797e2c783a2eb51214512bb192960420abed64f4.json | Update RBI files for rubocop. | Library/Homebrew/sorbet/rbi/gems/rubocop@1.5.1.rbi | @@ -22,6 +22,7 @@ class RuboCop::CLI
def handle_exiting_options; end
def run_command(name); end
def set_options_to_config_loader; end
+ def suggest_extensions; end
def validate_options_vs_config; end
end
@@ -87,9 +88,11 @@ class RuboCop::CLI::Command::ExecuteRunner < ::RuboCop::CLI::Command::Base
pri... | false |
Other | Homebrew | brew | 1064678d3dd8b0acc03a9a71abab09d1d818990c.json | Add audit for unversioned URLs with checksum. | Library/Homebrew/cask/audit.rb | @@ -248,6 +248,7 @@ def check_sha256
return unless cask.sha256
check_sha256_no_check_if_latest
+ check_sha256_no_check_if_unversioned
check_sha256_actually_256
check_sha256_invalid
end
@@ -260,6 +261,12 @@ def check_sha256_no_check_if_latest
add_error "you should use sha25... | false |
Other | Homebrew | brew | a0e0925f8eb1dc073b86da68e24341f5aea6b42d.json | Update RBI files for sorbet. | Library/Homebrew/sorbet/rbi/hidden-definitions/hidden.rbi | @@ -7675,6 +7675,11 @@ module Homebrew
MIN_PORT = ::T.let(nil, ::T.untyped)
end
+class Homebrew::BundleVersion
+ extend ::T::Private::Methods::MethodHooks
+ extend ::T::Private::Methods::SingletonMethodHooks
+end
+
class Homebrew::CLI::Args
extend ::T::Private::Methods::MethodHooks
extend ::T::Private::M... | false |
Other | Homebrew | brew | 9c0bf12c7c8ae34e6eb3321880956384bb77549d.json | Update RBI files for rubocop-rails. | Library/Homebrew/sorbet/rbi/gems/rubocop-rails@2.9.1.rbi | @@ -683,8 +683,7 @@ class RuboCop::Cop::Rails::FindEach < ::RuboCop::Cop::Base
private
- def ignored?(relation_method); end
- def method_chain(node); end
+ def ignored?(node); end
end
RuboCop::Cop::Rails::FindEach::MSG = T.let(T.unsafe(nil), String)
@@ -723,8 +722,13 @@ RuboCop::Cop::Rails::HasManyOrHasOn... | true |
Other | Homebrew | brew | 9c0bf12c7c8ae34e6eb3321880956384bb77549d.json | Update RBI files for rubocop-rails. | Library/Homebrew/sorbet/rbi/hidden-definitions/hidden.rbi | @@ -7675,6 +7675,11 @@ module Homebrew
MIN_PORT = ::T.let(nil, ::T.untyped)
end
+class Homebrew::BundleVersion
+ extend ::T::Private::Methods::MethodHooks
+ extend ::T::Private::Methods::SingletonMethodHooks
+end
+
class Homebrew::CLI::Args
extend ::T::Private::Methods::MethodHooks
extend ::T::Private::M... | true |
Other | Homebrew | brew | 8e389c54561e6b39fdfeaf9b90d172d9c248d6c3.json | sorbet: Update RBI files.
Autogenerated by the [sorbet](https://github.com/Homebrew/brew/blob/master/.github/workflows/sorbet.yml) workflow. | Library/Homebrew/sorbet/rbi/hidden-definitions/hidden.rbi | @@ -7675,6 +7675,11 @@ module Homebrew
MIN_PORT = ::T.let(nil, ::T.untyped)
end
+class Homebrew::BundleVersion
+ extend ::T::Private::Methods::MethodHooks
+ extend ::T::Private::Methods::SingletonMethodHooks
+end
+
class Homebrew::CLI::Args
extend ::T::Private::Methods::MethodHooks
extend ::T::Private::M... | false |
Other | Homebrew | brew | 7fb1620c58c1f5f9fc47934c4c1460532b0074be.json | Enable check_repository_references conditionally
Enable check_repository_references when HOMEBREW_PREFIX == HOMEBREW_REPOSITORY.
Co-authored-by: Mike McQuaid <mike@mikemcquaid.com> | Library/Homebrew/formula_cellar_checks.rb | @@ -210,6 +210,7 @@ def check_python_packages(lib, deps)
end
def check_repository_references(prefix)
+ return if HOMEBREW_PREFIX != HOMEBREW_REPOSITORY
return unless prefix.directory?
keg = Keg.new(prefix) | false |
Other | Homebrew | brew | 5607e4a947cc8bc81c2bf05009658d14e67dcd39.json | dev-cmd/pr-automerge: exclude draft PR | Library/Homebrew/dev-cmd/pr-automerge.rb | @@ -44,7 +44,7 @@ def pr_automerge
without_labels = args.without_labels || ["do not merge", "new formula", "automerge-skip", "linux-only"]
tap = Tap.fetch(args.tap || CoreTap.instance.name)
- query = "is:pr is:open repo:#{tap.full_name}"
+ query = "is:pr is:open repo:#{tap.full_name} draft:false"
... | false |
Other | Homebrew | brew | 1acb085574ab1560e55ecf21e6e7194ff435227e.json | update-report: summarize updated casks for --preinstall
Also, show less output if --quiet is passed. | Library/Homebrew/cmd/update-report.rb | @@ -66,7 +66,7 @@ def update_report
HOMEBREW_REPOSITORY.cd do
donation_message_displayed =
Utils.popen_read("git", "config", "--get", "homebrew.donationmessage").chomp == "true"
- unless donation_message_displayed
+ if !donation_message_displayed && !args.quiet?
ohai "Homebrew is... | false |
Other | Homebrew | brew | 91d6009891e84ec1a19bc3b9edabf4db4f96b184.json | Remove special case for XQuartz. | Library/Homebrew/test/bundle_version_spec.rb | @@ -6,18 +6,17 @@
describe Homebrew::BundleVersion do
describe "#nice_version" do
expected_mappings = {
- ["1.2", nil] => "1.2",
- [nil, "1.2.3"] => "1.2.3",
- ["1.2", "1.2.3"] => "1.2.3",
- ["1.2.3", "1.2"] => "1.2.3",
- ["1.2.... | false |
Other | Homebrew | brew | 7b9556db0618e3b3752d74572a3c4108a36878fe.json | Remove trailing `version` from `short_version`. | Library/Homebrew/bundle_version.rb | @@ -67,6 +67,8 @@ def nice_version
sig { returns(T::Array[String]) }
def nice_parts
+ short_version = self.short_version&.delete_suffix("(#{version})") if version
+
return [short_version] if short_version == version
if short_version && version | true |
Other | Homebrew | brew | 7b9556db0618e3b3752d74572a3c4108a36878fe.json | Remove trailing `version` from `short_version`. | Library/Homebrew/test/bundle_version_spec.rb | @@ -17,6 +17,7 @@
["1.2.3.4000", "4000"] => "1.2.3.4000",
["5", "5.0.45"] => "5.0.45",
["XQuartz-2.7.11", "2.7.112"] => "2.7.11",
+ ["2.5.2(3329)", "3329"] => "2.5.2,3329",
}
expected_mappings.each do |(short_version, version), expected_version| | true |
Other | Homebrew | brew | 7c6116af992b5fda8bc175277d862ef03624c984.json | Remove fallback for `BundleVersion`. | Library/Homebrew/bundle_version.rb | @@ -80,9 +80,7 @@ def nice_parts
end
end
- fallback = (short_version || version).sub(/\A[^\d]+/, "")
-
- [fallback]
+ [short_version, version].compact
end
private :nice_parts
end | false |
Other | Homebrew | brew | 831d034303bf972f6b4a872d5abdf6acb3439656.json | software_spec: fix cellar any handling.
`cellar :any` actually requires no references to the cellar, prefix or
repository (not just cellar) so we can pour those bottles anywhere
regardless of the cellar, prefix or repository. | Library/Homebrew/software_spec.rb | @@ -369,16 +369,18 @@ def root_url(var = nil, specs = {})
end
def compatible_locations?
- compatible_cellar = cellar == :any ||
- cellar == :any_skip_relocation ||
- cellar == HOMEBREW_CELLAR.to_s
+ # this looks like it should check prefix and repository too b... | false |
Other | Homebrew | brew | 33483e9478bf8b48f69b1c517e634f499a47094b.json | Fix install --force-bottle for non-standard prefix
Fix the error:
Error: undefined method `stage' for nil:NilClass
formula_installer.rb:1132:in `block in pour' | Library/Homebrew/formula_installer.rb | @@ -347,7 +347,7 @@ def install
# Warn if a more recent version of this formula is available in the tap.
begin
- if formula.pkg_version < (v = Formulary.factory(formula.full_name).pkg_version)
+ if formula.pkg_version < (v = Formulary.factory(formula.full_name, force_bottle: force_bottle?).pkg_ver... | false |
Other | Homebrew | brew | 91608a67f28f3f481e93180d398056374ae8ece2.json | sorbet: Update RBI files.
Autogenerated by the [sorbet](https://github.com/Homebrew/brew/blob/master/.github/workflows/sorbet.yml) workflow. | Library/Homebrew/sorbet/rbi/hidden-definitions/hidden.rbi | @@ -11477,6 +11477,79 @@ class Migrator
extend ::T::Private::Methods::SingletonMethodHooks
end
+class MiniPortile
+ def activate(); end
+
+ def apply_patch(patch_file); end
+
+ def compile(); end
+
+ def configure(); end
+
+ def configure_options(); end
+
+ def configure_options=(configure_options); end
+
+... | false |
Other | Homebrew | brew | f711352cfd222ee3281afc8594cf3392e03eeb06.json | Add audit for `livecheck` in casks. | Library/Homebrew/cask/audit.rb | @@ -4,6 +4,7 @@
require "cask/denylist"
require "cask/download"
require "digest"
+require "livecheck/livecheck"
require "utils/curl"
require "utils/git"
require "utils/shared_audits"
@@ -66,10 +67,11 @@ def run!
check_single_uninstall_zap
check_untrusted_pkg
check_hosting_with_appcast
- ... | true |
Other | Homebrew | brew | f711352cfd222ee3281afc8594cf3392e03eeb06.json | Add audit for `livecheck` in casks. | Library/Homebrew/cli/args.rbi | @@ -24,6 +24,15 @@ module Homebrew
sig { returns(T.nilable(T::Boolean)) }
def force_bottle?; end
+ sig { returns(T.nilable(T::Boolean)) }
+ def newer_only?; end
+
+ sig { returns(T.nilable(T::Boolean)) }
+ def full_name?; end
+
+ sig { returns(T.nilable(T::Boolean)) }
+ def... | true |
Other | Homebrew | brew | f711352cfd222ee3281afc8594cf3392e03eeb06.json | Add audit for `livecheck` in casks. | Library/Homebrew/dev-cmd/livecheck.rb | @@ -101,6 +101,15 @@ def livecheck
raise UsageError, "No formulae or casks to check." if formulae_and_casks_to_check.blank?
- Livecheck.run_checks(formulae_and_casks_to_check, args)
+ options = {
+ json: args.json?,
+ full_name: args.full_name?,
+ newer_only: args.newer_only?,
+ ... | true |
Other | Homebrew | brew | f711352cfd222ee3281afc8594cf3392e03eeb06.json | Add audit for `livecheck` in casks. | Library/Homebrew/livecheck/livecheck.rb | @@ -12,6 +12,8 @@ module Homebrew
#
# @api private
module Livecheck
+ extend T::Sig
+
module_function
GITEA_INSTANCES = %w[
@@ -41,10 +43,25 @@ module Livecheck
rc
].freeze
+ def livecheck_strategy_names
+ return @livecheck_strategy_names if defined?(@livecheck_strategy_nam... | true |
Other | Homebrew | brew | f711352cfd222ee3281afc8594cf3392e03eeb06.json | Add audit for `livecheck` in casks. | Library/Homebrew/test/livecheck/livecheck_spec.rb | @@ -91,35 +91,29 @@
RUBY
end
- let(:args) { double("livecheck_args", full_name?: false, json?: false, quiet?: false, verbose?: true) }
-
describe "::formula_name" do
it "returns the name of the formula" do
- expect(livecheck.formula_name(f, args: args)).to eq("test")
+ expect(livecheck.form... | true |
Other | Homebrew | brew | 87b914387f9510bc7beea40214cc2be6e303c948.json | Update RBI files for sorbet. | Library/Homebrew/sorbet/rbi/hidden-definitions/hidden.rbi | @@ -7723,6 +7723,8 @@ module Homebrew::EnvConfig
def self.cleanup_max_age_days(); end
+ def self.cleanup_periodic_full_days(); end
+
def self.color?(); end
def self.core_git_remote(); end
@@ -27645,6 +27647,8 @@ class RuboCop::Cask::AST::Stanza
def language?(); end
+ def livecheck?(); end
+
d... | false |
Other | Homebrew | brew | 4f0b7255acde456c8eba6016c7f0f507205f925a.json | style: add two options | Library/Homebrew/dev-cmd/style.rb | @@ -29,24 +29,32 @@ def style_args
description: "Include the RuboCop cop name for each violation in the output."
switch "--reset-cache",
description: "Reset the RuboCop cache."
+ switch "--formula", "--formulae",
+ description: "Treat all named arguments as formulae."... | true |
Other | Homebrew | brew | 4f0b7255acde456c8eba6016c7f0f507205f925a.json | style: add two options | docs/Manpage.md | @@ -1233,6 +1233,10 @@ including core code and all formulae.
Include the RuboCop cop name for each violation in the output.
* `--reset-cache`:
Reset the RuboCop cache.
+* `--formula`:
+ Treat all named arguments as formulae.
+* `--cask`:
+ Treat all named arguments as casks.
* `--only-cops`:
Specify a comm... | true |
Other | Homebrew | brew | 4f0b7255acde456c8eba6016c7f0f507205f925a.json | style: add two options | manpages/brew.1 | @@ -1708,6 +1708,14 @@ Include the RuboCop cop name for each violation in the output\.
Reset the RuboCop cache\.
.
.TP
+\fB\-\-formula\fR
+Treat all named arguments as formulae\.
+.
+.TP
+\fB\-\-cask\fR
+Treat all named arguments as casks\.
+.
+.TP
\fB\-\-only\-cops\fR
Specify a comma\-separated \fIcops\fR list to... | true |
Other | Homebrew | brew | 704ec8abf0ba613bbf594254f3da0fc04ba200a2.json | livecheck: reinstate previous order of hashes | Library/Homebrew/livecheck/livecheck.rb | @@ -153,19 +153,18 @@ def run_checks(formulae_and_casks_to_check, args)
is_newer_than_upstream = (formula&.stable? || cask) && (current > latest)
- info = {
- version: {
- current: current.to_s,
- latest: latest.to_s,
- outdated: ... | false |
Other | Homebrew | brew | ad544e465d45da47699b1e4b4bc47a2a05ebd782.json | Add livecheck group to cask stanza order | Library/Homebrew/rubocops/cask/constants/stanza.rb | @@ -9,6 +9,7 @@ module Constants
[:version, :sha256],
[:language],
[:url, :appcast, :name, :desc, :homepage],
+ [:livecheck],
[
:auto_updates,
:conflicts_with, | false |
Other | Homebrew | brew | b8e10a47ddeb9222392fb168c57d5a7c0013e851.json | Update man page. | docs/Manpage.md | @@ -1044,27 +1044,31 @@ provided, check all kegs. Raises an error if run on uninstalled formulae.
* `--cached`:
Print the cached linkage values stored in `HOMEBREW_CACHE`, set by a previous `brew linkage` run.
-### `livecheck` [*`formulae`*]
+### `livecheck` [*`formulae`*|*`casks`*]
-Check for newer versions of... | true |
Other | Homebrew | brew | b8e10a47ddeb9222392fb168c57d5a7c0013e851.json | Update man page. | manpages/brew.1 | @@ -1442,31 +1442,31 @@ For every library that a keg references, print its dylib path followed by the bi
\fB\-\-cached\fR
Print the cached linkage values stored in \fBHOMEBREW_CACHE\fR, set by a previous \fBbrew linkage\fR run\.
.
-.SS "\fBlivecheck\fR [\fIformulae\fR]"
-Check for newer versions of formulae from ups... | true |
Other | Homebrew | brew | fa64a17ae9d5c09c3dac84accaa76eb8e3478ea3.json | Remove superfluous branch. | Library/Homebrew/livecheck/livecheck.rb | @@ -116,9 +116,6 @@ def run_checks(formulae_and_casks_to_check, args)
livecheck_version = formula_or_cask.livecheck.version
current = if livecheck_version.is_a?(String)
Version.new(livecheck_version)
- elsif livecheck_version.is_a?(Array)
- separator, method = livecheck_vers... | false |
Other | Homebrew | brew | af56a99a37d93c252392129ab44ee18ea884c447.json | Use symbol for `respond_to?`. | Library/Homebrew/dev-cmd/livecheck.rb | @@ -97,7 +97,7 @@ def livecheck
onoe e
end
end.sort_by do |formula_or_cask|
- formula_or_cask.respond_to?("token") ? formula_or_cask.token : formula_or_cask.name
+ formula_or_cask.respond_to?(:token) ? formula_or_cask.token : formula_or_cask.name
end
raise UsageError, "No form... | false |
Other | Homebrew | brew | 3b366d05b9c8a29a89bbf773fd2557024ea977b1.json | Fix code style. | Library/Homebrew/cask/dsl.rb | @@ -278,7 +278,7 @@ def auto_updates(auto_updates = nil)
def livecheck(&block)
@livecheck ||= Livecheck.new(self)
- return @livecheck unless block_given?
+ return @livecheck unless block
raise CaskInvalidError.new(cask, "'livecheck' stanza may only appear once.") if @livecheckable
| true |
Other | Homebrew | brew | 3b366d05b9c8a29a89bbf773fd2557024ea977b1.json | Fix code style. | Library/Homebrew/dev-cmd/livecheck.rb | @@ -61,16 +61,16 @@ def livecheck
formulae_and_casks_to_check = if args.tap
tap = Tap.fetch(args.tap)
- formulae = !args.cask? ? tap.formula_names.map { |name| Formula[name] } : []
- casks = !args.formula? ? tap.cask_tokens.map { |token| Cask::CaskLoader.load(token) } : []
+ formulae = args... | true |
Other | Homebrew | brew | 3b366d05b9c8a29a89bbf773fd2557024ea977b1.json | Fix code style. | Library/Homebrew/livecheck/livecheck.rb | @@ -120,15 +120,15 @@ def run_checks(formulae_and_casks_to_check, args)
separator, method = livecheck_version
Version.new(formula_or_cask.version.to_s.split(separator, 2).try(method))
elsif formula
- if formula.head_only?
- formula.any_installed_version.version.com... | true |
Other | Homebrew | brew | 064e93df5b32c9914fcfaf9702cd32ba4d7b7ebb.json | Collapse checkable_urls methods into one method | Library/Homebrew/livecheck/livecheck.rb | @@ -339,36 +339,28 @@ def print_latest_version(info, args:)
puts "#{formula_or_cask_s} : #{current_s} ==> #{latest_s}"
end
- # Returns an Array containing the formula URLs that can be used by livecheck.
+ # Returns an Array containing the formula/cask URLs that can be used by livecheck.
# @retu... | false |
Other | Homebrew | brew | bf03893227dd7602d14852ff4dd34325dd4840df.json | Add appcast to checkable cask urls | Library/Homebrew/livecheck/livecheck.rb | @@ -358,6 +358,7 @@ def checkable_formula_urls(formula)
def checkable_cask_urls(cask)
urls = []
+ urls << cask.appcast.to_s if cask.appcast
urls << cask.url.to_s
urls << cask.homepage if cask.homepage
urls.compact | false |
Other | Homebrew | brew | 6794a78087991f84efc8f0a959a85c411733f3a3.json | livecheck: add support for casks | Library/Homebrew/cask/dsl.rb | @@ -3,6 +3,7 @@
require "locale"
require "lazy_object"
+require "livecheck"
require "cask/artifact"
@@ -81,6 +82,8 @@ class DSL
:version,
:appdir,
:discontinued?,
+ :livecheck,
+ ... | true |
Other | Homebrew | brew | 6794a78087991f84efc8f0a959a85c411733f3a3.json | livecheck: add support for casks | Library/Homebrew/dev-cmd/livecheck.rb | @@ -54,28 +54,28 @@ def livecheck
puts ENV["HOMEBREW_LIVECHECK_WATCHLIST"] if ENV["HOMEBREW_LIVECHECK_WATCHLIST"].present?
end
- formulae_to_check = if args.tap
- Tap.fetch(args.tap).formula_names.map { |name| Formula[name] }
+ formulae_and_casks_to_check = if args.tap
+ tap = Tap.fetch(ar... | true |
Other | Homebrew | brew | 6794a78087991f84efc8f0a959a85c411733f3a3.json | livecheck: add support for casks | Library/Homebrew/livecheck.rb | @@ -1,20 +1,20 @@
# typed: true
# frozen_string_literal: true
-# The {Livecheck} class implements the DSL methods used in a formula's
+# The {Livecheck} class implements the DSL methods used in a formula's or cask's
# `livecheck` block and stores related instance variables. Most of these methods
# also return the... | true |
Other | Homebrew | brew | 6794a78087991f84efc8f0a959a85c411733f3a3.json | livecheck: add support for casks | Library/Homebrew/livecheck/livecheck.rb | @@ -41,18 +41,18 @@ module Livecheck
rc
].freeze
- # Executes the livecheck logic for each formula in the `formulae_to_check` array
- # and prints the results.
+ # Executes the livecheck logic for each formula/cask in the
+ # `formulae_and_casks_to_check` array and prints the results.
# @... | true |
Other | Homebrew | brew | 6794a78087991f84efc8f0a959a85c411733f3a3.json | livecheck: add support for casks | Library/Homebrew/test/livecheck/livecheck_spec.rb | @@ -74,6 +74,24 @@
end
end
+ let(:c) do
+ Cask::CaskLoader.load(+<<-RUBY)
+ cask "test" do
+ version "0.0.1,2"
+
+ url "https://brew.sh/test-0.0.1.tgz"
+ name "Test"
+ homepage "https://brew.sh"
+
+ livecheck do
+ url "https://formulae.brew.sh/api/formula/r... | true |
Other | Homebrew | brew | 6794a78087991f84efc8f0a959a85c411733f3a3.json | livecheck: add support for casks | Library/Homebrew/test/livecheck_spec.rb | @@ -107,6 +107,26 @@
end
end
+ describe "#version" do
+ it "returns nil if not set" do
+ expect(livecheckable.version).to be nil
+ end
+
+ it "returns value if set" do
+ livecheckable.version("foo")
+ expect(livecheckable.version).to eq("foo")
+
+ livecheckable.version(:before_co... | true |
Other | Homebrew | brew | 5b770e99651c15e9835356a9a3d59a6ffcd91584.json | Cpan: Reimplement strategy and improve tests
Co-authored-by: Dario Vladovic <d.vladimyr@gmail.com> | Library/Homebrew/livecheck/strategy/cpan.rb | @@ -1,34 +1,34 @@
# typed: false
# frozen_string_literal: true
-require "uri"
-
module Homebrew
module Livecheck
module Strategy
# The {Cpan} strategy identifies versions of software at
# cpan.metacpan.org by checking directory listing pages.
#
- # CPAN URLs take the following for... | true |
Other | Homebrew | brew | 5b770e99651c15e9835356a9a3d59a6ffcd91584.json | Cpan: Reimplement strategy and improve tests
Co-authored-by: Dario Vladovic <d.vladimyr@gmail.com> | Library/Homebrew/test/livecheck/strategy/cpan_spec.rb | @@ -6,12 +6,14 @@
describe Homebrew::Livecheck::Strategy::Cpan do
subject(:cpan) { described_class }
- let(:cpan_url) { "https://cpan.metacpan.org/authors/id/M/MI/MIYAGAWA/Carton-v1.0.34.tar.gz" }
+ let(:cpan_url_no_subdirectory) { "https://cpan.metacpan.org/authors/id/H/HO/HOMEBREW/Brew-v1.2.3.tar.gz" }
+ let... | true |
Other | Homebrew | brew | 9dec442e715a351791bc9ce18cae57d96cb718b5.json | pr-pull: prepare replacement for --workflow flag | Library/Homebrew/cli/parser.rb | @@ -194,16 +194,21 @@ def comma_array(name, description: nil)
end
end
- def flag(*names, description: nil, required_for: nil, depends_on: nil)
+ def flag(*names, description: nil, replacement: nil, required_for: nil, depends_on: nil)
required = if names.any? { |name| name.end_with? ... | true |
Other | Homebrew | brew | 9dec442e715a351791bc9ce18cae57d96cb718b5.json | pr-pull: prepare replacement for --workflow flag | Library/Homebrew/dev-cmd/pr-pull.rb | @@ -51,7 +51,9 @@ def pr_pull_args
description: "Message to include when autosquashing revision bumps, deletions, and rebuilds."
flag "--workflow=",
description: "Retrieve artifacts from the specified workflow (default: `tests.yml`). "\
- "Legacy: use --work... | true |
Other | Homebrew | brew | 9dec442e715a351791bc9ce18cae57d96cb718b5.json | pr-pull: prepare replacement for --workflow flag | docs/Manpage.md | @@ -1141,7 +1141,7 @@ Requires write access to the repository.
* `--message`:
Message to include when autosquashing revision bumps, deletions, and rebuilds.
* `--workflow`:
- Retrieve artifacts from the specified workflow (default: `tests.yml`). Legacy: use --workflows instead
+ Retrieve artifacts from the speci... | true |
Other | Homebrew | brew | 9dec442e715a351791bc9ce18cae57d96cb718b5.json | pr-pull: prepare replacement for --workflow flag | manpages/brew.1 | @@ -1589,7 +1589,7 @@ Message to include when autosquashing revision bumps, deletions, and rebuilds\.
.
.TP
\fB\-\-workflow\fR
-Retrieve artifacts from the specified workflow (default: \fBtests\.yml\fR)\. Legacy: use \-\-workflows instead
+Retrieve artifacts from the specified workflow (default: \fBtests\.yml\fR)\. ... | true |
Other | Homebrew | brew | 9ecdf117b3f8b68dde5bc98407ffffc9f73cc5bc.json | Fix broken output on CI. | Library/Homebrew/brew.rb | @@ -46,6 +46,11 @@ class MissingEnvironmentVariables < RuntimeError; end
begin
trap("INT", std_trap) # restore default CTRL-C handler
+ if ENV["CI"]
+ $stdout.sync = true
+ $stderr.sync = true
+ end
+
empty_argv = ARGV.empty?
help_flag_list = %w[-h --help --usage -?]
help_flag = !ENV["HOMEBREW_HE... | false |
Other | Homebrew | brew | 402600a94fa9eb3dd9ade82f5edf64a890f159d6.json | docs: add documentation for plists | docs/Formula-Cookbook.md | @@ -749,6 +749,40 @@ Homebrew provides two formula DSL methods for launchd plist files:
* [`plist_name`](https://rubydoc.brew.sh/Formula#plist_name-instance_method) will return e.g. `homebrew.mxcl.<formula>`
* [`plist_path`](https://rubydoc.brew.sh/Formula#plist_path-instance_method) will return e.g. `/usr/local/Cell... | false |
Other | Homebrew | brew | 68e2e48b63246f7417885b7f00dfbf7800427d4e.json | Update the variable names | Library/Homebrew/cmd/update.sh | @@ -390,17 +390,17 @@ EOS
fi
fi
- [[ -f "$HOMEBREW_LIBRARY/Taps/homebrew/homebrew-core/.git/shallow" ]] && SHALLOW_CORE=1
- [[ -f "$HOMEBREW_LIBRARY/Taps/homebrew/homebrew-cask/.git/shallow" ]] && SHALLOW_CASK=1
+ [[ -f "$HOMEBREW_LIBRARY/Taps/homebrew/homebrew-core/.git/shallow" ]] && HOMEBREW_CORE_SHALLO... | false |
Other | Homebrew | brew | eb74717a9e24eb94de9a60508a208b224dff8172.json | Fix unbottled dependency handling
- Rename `BuildToolsError` to `UnbottledError` to better reflect what it
does (particularly now)
- Improve the `UnbottledError` messaging
- Raise the `UnbottledError` for dependencies also when building bottles
(so that we don't try and build bottles against things that have been
... | Library/Homebrew/exceptions.rb | @@ -488,17 +488,18 @@ def dump(verbose: false)
end
end
-# Raised by {FormulaInstaller#check_dependencies_bottled} and
-# {FormulaInstaller#install} if the formula or its dependencies are not bottled
-# and are being installed on a system without necessary build tools.
-class BuildToolsError < RuntimeError
+# Rais... | true |
Other | Homebrew | brew | eb74717a9e24eb94de9a60508a208b224dff8172.json | Fix unbottled dependency handling
- Rename `BuildToolsError` to `UnbottledError` to better reflect what it
does (particularly now)
- Improve the `UnbottledError` messaging
- Raise the `UnbottledError` for dependencies also when building bottles
(so that we don't try and build bottles against things that have been
... | Library/Homebrew/formula_installer.rb | @@ -356,11 +356,17 @@ def install
check_conflicts
- raise BuildToolsError, [formula] if !pour_bottle? && !formula.bottle_unneeded? && !DevelopmentTools.installed?
+ raise UnbottledError, [formula] if !pour_bottle? && !formula.bottle_unneeded? && !DevelopmentTools.installed?
unless ignore_deps?
... | true |
Other | Homebrew | brew | eb74717a9e24eb94de9a60508a208b224dff8172.json | Fix unbottled dependency handling
- Rename `BuildToolsError` to `UnbottledError` to better reflect what it
does (particularly now)
- Improve the `UnbottledError` messaging
- Raise the `UnbottledError` for dependencies also when building bottles
(so that we don't try and build bottles against things that have been
... | Library/Homebrew/test/formula_installer_bottle_spec.rb | @@ -83,7 +83,7 @@ def temporarily_install_bottle(formula)
expect {
described_class.new(formula).install
- }.to raise_error(BuildToolsError)
+ }.to raise_error(UnbottledError)
expect(formula).not_to be_latest_version_installed
end | true |
Other | Homebrew | brew | 16d13fe086f191a0b39e08f2d8e96daa292e5f78.json | add two options to cmd/home | Library/Homebrew/cmd/home.rb | @@ -18,6 +18,11 @@ def home_args
Open a <formula> or <cask>'s homepage in a browser, or open
Homebrew's own homepage if no argument is provided.
EOS
+ switch "--formula", "--formulae",
+ description: "Treat all named arguments as formulae."
+ switch "--cask", "--casks",
+ ... | true |
Other | Homebrew | brew | 16d13fe086f191a0b39e08f2d8e96daa292e5f78.json | add two options to cmd/home | docs/Manpage.md | @@ -211,6 +211,11 @@ error message if no logs are found.
Open a *`formula`* or *`cask`*'s homepage in a browser, or open
Homebrew's own homepage if no argument is provided.
+* `--formula`:
+ Treat all named arguments as formulae.
+* `--cask`:
+ Treat all named arguments as casks.
+
### `info` [*`options`*] [*`fo... | true |
Other | Homebrew | brew | 16d13fe086f191a0b39e08f2d8e96daa292e5f78.json | add two options to cmd/home | manpages/brew.1 | @@ -258,6 +258,14 @@ The Gist will be marked private and will not appear in listings but will be acce
.SS "\fBhome\fR [\fIformula\fR|\fIcask\fR]"
Open a \fIformula\fR or \fIcask\fR\'s homepage in a browser, or open Homebrew\'s own homepage if no argument is provided\.
.
+.TP
+\fB\-\-formula\fR
+Treat all named argum... | true |
Other | Homebrew | brew | 323fec503201eb66bf981f8fab034238db428aae.json | utils/bottles: install bundler gems if necessary. | Library/Homebrew/utils/bottles.rb | @@ -76,6 +76,7 @@ def formula_contents(bottle_file,
end
def add_bottle_stanza!(formula_contents, bottle_output)
+ Homebrew.install_bundler_gems!
require "rubocop-ast"
ruby_version = Version.new(HOMEBREW_REQUIRED_RUBY_VERSION).major_minor.to_f | false |
Other | Homebrew | brew | b8aa67be5b0aaac8c027cd57a61213150c12c55a.json | bottle: add bottle stanza by traversing AST | Library/Homebrew/dev-cmd/bottle.rb | @@ -536,27 +536,7 @@ def merge(args:)
odie "--keep-old was passed but there was no existing bottle block!" if args.keep_old?
puts output
update_or_add = "add"
- pattern = /(
- (\ {2}\#[^\n]*\n)* # comments
- ... | true |
Other | Homebrew | brew | b8aa67be5b0aaac8c027cd57a61213150c12c55a.json | bottle: add bottle stanza by traversing AST | Library/Homebrew/rubocops/components_order.rb | @@ -11,50 +11,50 @@ module FormulaAudit
# - `component_precedence_list` has component hierarchy in a nested list
# where each sub array contains components' details which are at same precedence level
class ComponentsOrder < FormulaCop
- def audit_formula(_node, _class_node, _parent_class_n... | true |
Other | Homebrew | brew | b8aa67be5b0aaac8c027cd57a61213150c12c55a.json | bottle: add bottle stanza by traversing AST | Library/Homebrew/rubocops/shared/helper_functions.rb | @@ -1,6 +1,8 @@
# typed: false
# frozen_string_literal: true
+require "rubocop"
+
module RuboCop
module Cop
# Helper functions for cops. | true |
Other | Homebrew | brew | b8aa67be5b0aaac8c027cd57a61213150c12c55a.json | bottle: add bottle stanza by traversing AST | Library/Homebrew/test/utils/bottles/bottles_spec.rb | @@ -14,4 +14,262 @@
end
end
end
+
+ describe "#add_bottle_stanza!" do
+ let(:bottle_output) do
+ require "active_support/core_ext/string/indent"
+
+ <<~RUBY.chomp.indent(2)
+ bottle do
+ sha256 "f7b1fc772c79c20fddf621ccc791090bc1085fcef4da6cca03399424c66e06ca" => :sierra
+ ... | true |
Other | Homebrew | brew | b8aa67be5b0aaac8c027cd57a61213150c12c55a.json | bottle: add bottle stanza by traversing AST | Library/Homebrew/utils/bottles.rb | @@ -74,6 +74,77 @@ def formula_contents(bottle_file,
contents
end
+
+ def add_bottle_stanza!(formula_contents, bottle_output)
+ require "rubocop-ast"
+
+ ruby_version = Version.new(HOMEBREW_REQUIRED_RUBY_VERSION).major_minor.to_f
+ processed_source = RuboCop::AST::ProcessedSo... | true |
Other | Homebrew | brew | c4da30230344247a8f61655c48ee5df2ba8801d7.json | on_macos/on_linux block: improve rubocop message
Co-authored-by: Markus Reiter <me@reitermark.us> | Library/Homebrew/rubocops.rb | @@ -3,6 +3,8 @@
require_relative "load_path"
+require "active_support/core_ext/array/conversions"
+
require "utils/sorbet"
require "rubocop-performance" | true |
Other | Homebrew | brew | c4da30230344247a8f61655c48ee5df2ba8801d7.json | on_macos/on_linux block: improve rubocop message
Co-authored-by: Markus Reiter <me@reitermark.us> | Library/Homebrew/rubocops/components_order.rb | @@ -135,6 +135,7 @@ def audit_formula(_node, _class_node, _parent_class_node, body_node)
end
def check_on_os_block_content(component_precedence_list, on_os_block)
+ on_os_allowed_methods = %w[depends_on patch resource deprecate! disable!]
_, offensive_node = check_order(component... | true |
Other | Homebrew | brew | c4da30230344247a8f61655c48ee5df2ba8801d7.json | on_macos/on_linux block: improve rubocop message
Co-authored-by: Markus Reiter <me@reitermark.us> | Library/Homebrew/test/rubocops/components_order_spec.rb | @@ -390,9 +390,9 @@ class Foo < Formula
class Foo < Formula
url "https://brew.sh/foo-1.0.tgz"
on_macos do
- ^^^^^^^^^^^ `on_macos` can only include `depends_on`, `patch` and `resource` nodes.
depends_on "readline"
uses_from_macos "ncurses"
+ ^^^^^^^^^^^^^^^... | true |
Other | Homebrew | brew | cb2facfec13f38ccd0926a35af4678b0ca6eb777.json | Ignore `Info.plist` for nested apps. | Library/Homebrew/unversioned_cask_checker.rb | @@ -104,7 +104,10 @@ def guess_cask_version
end
info_plist_paths = apps.flat_map do |app|
- Pathname.glob(dir/"**"/app.source.basename/"Contents"/"Info.plist")
+ Pathname.glob(dir/"**"/app.source.basename/"Contents"/"Info.plist").reject do |info_plist_path|
+ # Ignore ne... | false |
Other | Homebrew | brew | e902558f9dc4dd3c09067f0419ad9e047e63023e.json | Update RBI files for sorbet. | Library/Homebrew/sorbet/rbi/hidden-definitions/hidden.rbi | @@ -8118,7 +8118,6 @@ class HeadVersion
end
module Homebrew
- DEFAULT_REPOSITORY = ::T.let(nil, ::T.untyped)
MAX_PORT = ::T.let(nil, ::T.untyped)
MIN_PORT = ::T.let(nil, ::T.untyped)
end | false |
Other | Homebrew | brew | 59cfef6db02a4c43c9ab777c17ce3cafd6803c8c.json | bump-formula-pr: handle additional edge cases | Library/Homebrew/dev-cmd/bump-formula-pr.rb | @@ -70,8 +70,8 @@ def bump_formula_pr_args
flag "--tag=",
description: "Specify the new git commit <tag> for the formula."
flag "--revision=",
- depends_on: "--tag=",
- description: "Specify the new git commit <revision> corresponding to the specified <tag>."
+ ... | true |
Other | Homebrew | brew | 59cfef6db02a4c43c9ab777c17ce3cafd6803c8c.json | bump-formula-pr: handle additional edge cases | docs/Manpage.md | @@ -889,7 +889,7 @@ nor vice versa. It must use whichever style specification the formula already us
* `--tag`:
Specify the new git commit *`tag`* for the formula.
* `--revision`:
- Specify the new git commit *`revision`* corresponding to the specified *`tag`*.
+ Specify the new commit *`revision`* corresponding... | true |
Other | Homebrew | brew | 59cfef6db02a4c43c9ab777c17ce3cafd6803c8c.json | bump-formula-pr: handle additional edge cases | manpages/brew.1 | @@ -1236,7 +1236,7 @@ Specify the new git commit \fItag\fR for the formula\.
.
.TP
\fB\-\-revision\fR
-Specify the new git commit \fIrevision\fR corresponding to the specified \fItag\fR\.
+Specify the new commit \fIrevision\fR corresponding to the specified git \fItag\fR or specified \fIversion\fR\.
.
.TP
\fB\-f\... | true |
Other | Homebrew | brew | 026381d359ab0c10b25d6f90ecdc27771bb5e227.json | Revert "untap: add --force switch" | Library/Homebrew/cmd/untap.rb | @@ -2,7 +2,6 @@
# frozen_string_literal: true
require "cli/parser"
-require "formula"
module Homebrew
extend T::Sig
@@ -17,8 +16,6 @@ def untap_args
Remove a tapped formula repository.
EOS
- switch "-f", "--force",
- description: "Untap even if formulae or casks from this ta... | true |
Other | Homebrew | brew | 026381d359ab0c10b25d6f90ecdc27771bb5e227.json | Revert "untap: add --force switch" | docs/Manpage.md | @@ -572,9 +572,6 @@ See also `pin`.
Remove a tapped formula repository.
-* `-f`, `--force`:
- Untap even if formulae or casks from this tap are currently installed.
-
### `update` [*`options`*]
Fetch the newest version of Homebrew and all formulae from GitHub using `git`(1) and perform any necessary migration... | true |
Other | Homebrew | brew | 026381d359ab0c10b25d6f90ecdc27771bb5e227.json | Revert "untap: add --force switch" | manpages/brew.1 | @@ -770,10 +770,6 @@ Unpin \fIformula\fR, allowing them to be upgraded by \fBbrew upgrade\fR \fIformu
.SS "\fBuntap\fR \fItap\fR"
Remove a tapped formula repository\.
.
-.TP
-\fB\-f\fR, \fB\-\-force\fR
-Untap even if formulae or casks from this tap are currently installed\.
-.
.SS "\fBupdate\fR [\fIoptions\fR]"
Fe... | true |
Other | Homebrew | brew | adab0fbb41676410229228e96d81f7d5319c719a.json | cleanup: fix portable Ruby behaviour.
Better match the macOS behaviour in `ruby.sh`.
Fixes #9469 | Library/Homebrew/brew.sh | @@ -455,6 +455,7 @@ export HOMEBREW_MACOS_VERSION_NUMERIC
export HOMEBREW_USER_AGENT
export HOMEBREW_USER_AGENT_CURL
export HOMEBREW_BOTTLE_DEFAULT_DOMAIN
+export HOMEBREW_MACOS_SYSTEM_RUBY_NEW_ENOUGH
if [[ -n "$HOMEBREW_MACOS" && -x "/usr/bin/xcode-select" ]]
then | true |
Other | Homebrew | brew | adab0fbb41676410229228e96d81f7d5319c719a.json | cleanup: fix portable Ruby behaviour.
Better match the macOS behaviour in `ruby.sh`.
Fixes #9469 | Library/Homebrew/cleanup.rb | @@ -361,6 +361,8 @@ def cleanup_portable_ruby
use_system_ruby = if Homebrew::EnvConfig.force_vendor_ruby?
false
+ elsif OS.mac?
+ ENV["HOMEBREW_MACOS_SYSTEM_RUBY_NEW_ENOUGH"].present?
else
check_ruby_version = HOMEBREW_LIBRARY_PATH/"utils/ruby_check_version_script.rb"
... | true |
Other | Homebrew | brew | 1f8fd2a9ef72a860e5775bcd64b4600d41e3b52e.json | caveats: remove ZSH FPATH logic.
This is too error-prone and full of edge cases.
Fixes #9455 | Library/Homebrew/caveats.rb | @@ -128,21 +128,10 @@ def function_completion_caveats(shell)
#{root_dir}/etc/bash_completion.d
EOS
when :zsh
- site_functions = root_dir/"share/zsh/site-functions"
- zsh_caveats = +<<~EOS
+ <<~EOS
zsh #{installed.join(" and ")} have been installed to:
- #{site_fun... | false |
Other | Homebrew | brew | eec1d5e17f3b13a5cf2055f662a7e5a2d8edc9bc.json | Add timeout in `bump-unversioned-casks`. | Library/Homebrew/dev-cmd/bump-unversioned-casks.rb | @@ -1,6 +1,7 @@
# typed: false
# frozen_string_literal: true
+require "timeout"
require "cask/download"
require "cask/installer"
require "cask/cask_loader"
@@ -45,18 +46,9 @@ def self.bump_unversioned_casks
state = state_file.exist? ? JSON.parse(state_file.read) : {}
- cask_files = args.named.to_path... | false |
Other | Homebrew | brew | 4c5fc62a5d5ebbcd1c18695a779e2fb353ed337b.json | sorbet: Update RBI files.
Autogenerated by the [sorbet](https://github.com/Homebrew/brew/blob/master/.github/workflows/sorbet.yml) workflow. | Library/Homebrew/sorbet/rbi/hidden-definitions/hidden.rbi | @@ -7086,6 +7086,8 @@ end
class Errno::EBADRPC
end
+Errno::ECAPMODE = Errno::NOERROR
+
Errno::EDEADLOCK = Errno::NOERROR
class Errno::EDEVERR
@@ -7106,6 +7108,13 @@ end
Errno::EIPSEC = Errno::NOERROR
+class Errno::ELAST
+ Errno = ::T.let(nil, ::T.untyped)
+end
+
+class Errno::ELAST
+end
+
class Errno::EN... | false |
Other | Homebrew | brew | 8717f82b9d7d3a05e7411a12434551474d4212f1.json | dev-cmd/audit: add audit for checksum | Library/Homebrew/resource_auditor.rb | @@ -26,6 +26,7 @@ def initialize(resource, spec_name, options = {})
def audit
audit_version
audit_download_strategy
+ audit_checksum
audit_urls
self
end
@@ -72,6 +73,13 @@ def audit_download_strategy
problem "Redundant :using value in URL"
end
+ def audit_chec... | true |
Other | Homebrew | brew | 8717f82b9d7d3a05e7411a12434551474d4212f1.json | dev-cmd/audit: add audit for checksum | Library/Homebrew/test/dev-cmd/audit_spec.rb | @@ -564,10 +564,46 @@ class Foo < Formula
let(:throttle_list) { { throttled_formulae: { "foo" => 10 } } }
let(:versioned_head_spec_list) { { versioned_head_spec_allowlist: ["foo"] } }
+ it "doesn't allow to miss a checksum" do
+ fa = formula_auditor "foo", <<~RUBY
+ class Foo < Form... | true |
Other | Homebrew | brew | 9b4a7856ac92e025e9df73ed5d18e4412fa55b5c.json | Revert "RbConfig: fix broken MacOS SDK paths"
This reverts commit 11445e0f3edf29ee64081c5a05b5257d9b5ccdd9. | Library/Homebrew/extend/rbconfig_extension.rb | @@ -1,17 +0,0 @@
-# typed: false
-# frozen_string_literal: true
-
-macos_version = ENV["HOMEBREW_MACOS_VERSION"][0..4]
-macos_sdk = "MacOSX#{macos_version}.sdk"
-
-# Ruby hardcodes what might end up being an incorrect SDK path in some of the
-# variables that get used in mkmf.rb.
-# This patches them up to use the corr... | true |
Other | Homebrew | brew | 9b4a7856ac92e025e9df73ed5d18e4412fa55b5c.json | Revert "RbConfig: fix broken MacOS SDK paths"
This reverts commit 11445e0f3edf29ee64081c5a05b5257d9b5ccdd9. | Library/Homebrew/utils/gems.rb | @@ -109,15 +109,6 @@ def install_bundler_gems!
install_bundler!
ENV["BUNDLE_GEMFILE"] = File.join(ENV.fetch("HOMEBREW_LIBRARY"), "Homebrew", "Gemfile")
-
- # We can't use OS.mac? because not enough has
- # been required yet this early in the boot process
- if ENV["HOMEBREW_SYSTEM"] == "Macintosh"
-... | true |
Other | Homebrew | brew | 16270ba185e889cfb92265301b34061a123692d4.json | software_spec: add on_macos/on_linux to SoftwareSpec | Library/Homebrew/software_spec.rb | @@ -12,11 +12,13 @@
require "compilers"
require "global"
require "os/mac/version"
+require "extend/on_os"
class SoftwareSpec
extend T::Sig
extend Forwardable
+ include OnOS
PREDEFINED_OPTIONS = {
universal: Option.new("universal", "Build a universal binary"), | false |
Other | Homebrew | brew | 509ab86ece78723efdca37fec286faf9c8ee896c.json | software_spec: add on_macos/on_linux to PourBottleCheck | Library/Homebrew/software_spec.rb | @@ -12,6 +12,7 @@
require "compilers"
require "global"
require "os/mac/version"
+require "extend/on_os"
class SoftwareSpec
extend T::Sig
@@ -408,6 +409,8 @@ def checksums
end
class PourBottleCheck
+ include OnOS
+
def initialize(formula)
@formula = formula
end | false |
Other | Homebrew | brew | c8a8b797306237404e6670dfd3cabe1edcf0639d.json | add path name to brew edit error message | Library/Homebrew/dev-cmd/edit.rb | @@ -46,7 +46,8 @@ def edit
next path if path.exist?
raise UsageError, "#{path} doesn't exist on disk. " \
- "Run #{Formatter.identifier("brew create $URL")} to create a new Formula!"
+ "Run #{Formatter.identifier("brew create --set-name #{path.basename} $URL... | false |
Other | Homebrew | brew | 3f10815f4f85e6279c9f739e6d3984855deb03d3.json | os/mac/pkgconfig: add pc files for Big Sur 11.1 | Library/Homebrew/os/mac/pkgconfig/11.1/expat.pc | @@ -0,0 +1,12 @@
+homebrew_sdkroot=/Library/Developer/CommandLineTools/SDKs/MacOSX11.1.sdk
+prefix=${homebrew_sdkroot}/usr
+exec_prefix=/usr
+libdir=${exec_prefix}/lib
+includedir=${prefix}/include
+
+Name: expat
+Version: 2.2.8
+Description: expat XML parser
+URL: http://www.libexpat.org
+Libs: -L${libdir} -lexpat
+Cf... | true |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.