apainintheneck
819af3cbdd
cmd/untap: fix installed formula & cask check
...
This wasn't working before for a few reasons.
1. It never got past the installed name check because the
installed name sets had short names and the tap names were
long names including the tap namespace too. Now we just trim the
long name before comparing it to the installed name set.
Before:
```
["name"].include?("tap/full/name") # always false
```
After:
```
["name"].include("tap/full/name".split("/").last) # sometimes true
```
2. The names we were trying to load formulae and casks with
were incorrect.
Before:
```
tap = Tap.fetch("homebrew/cask-versions")
token = "homebrew/cask-versions/token"
cask = Cask::CaskLoader.load("#{tap}/#{token}")
```
After:
```
token = "homebrew/cask-versions/token"
cask = CaskCaskLoader.load(token)
```
2024-03-10 22:33:33 -07:00
apainintheneck
fb8c0d2b30
s/Tap.select(&:installed?)/Tap.installed/
2024-03-08 23:22:00 -08:00
Mike McQuaid
9ac31827a0
Various brew update
behaviour improvements
...
- Output a message every time auto-update is run rather than a 3 second
timer. This makes it more obvious that Homebrew isn't just sitting
doing nothing for 2.9 seconds.
- Output a message when running `brew update` so Homebrew doesn't just
sit there silently doing nothing.
- Update all taps when `brew update` is run, not just those hosted on
GitHub. This makes it more obvious that people don't need to explictly
run `brew update` "just in case".
- As a result of this, remove `brew tap --force-auto-update` as it's no
longer necessary.
2024-03-08 16:21:09 +00:00
Mike McQuaid
f1f92d28bf
Merge branch 'master' into lail/add-overwrite-flag-to-brew-upgrade
2024-03-08 08:27:04 +00:00
Bob
3d24da1904
Add support for the --overwrite
flag to brew upgrade
to govern the keg-linking step
...
`FormulaInstaller` already supports this (https://github.com/Homebrew/brew/pull/12691 ) but I didn't wire it up via `brew upgrade` and the two can be used largely interchangeably
2024-03-07 13:13:28 -08:00
Mike McQuaid
ea2892f8ee
brew.rb: handle missing args.
2024-03-07 16:20:20 +00:00
Douglas Eichelberger
fe439e8320
Apply 'chmod -x' to executables without shebangs
2024-03-06 22:22:49 -08:00
Markus Reiter
3da0f8c4a6
Fix loading casks/formulae from relative paths.
2024-03-01 04:05:15 +01:00
Patrick Linnane
faf399716f
Fix Style/RedundantLineContinuation
offenses
...
Signed-off-by: Patrick Linnane <patrick@linnane.io>
2024-02-29 09:26:51 -08:00
Markus Reiter
e08e873921
Only show installed taps in brew tap
output.
2024-02-28 20:18:55 +01:00
Markus Reiter
18571e8991
Merge pull request #16732 from reitermarkus/repo-var-suffix
...
Rename `Tap#repo_var` to `Tap#repo_var_suffix`.
2024-02-27 11:26:16 +01:00
Issy Long
f4218a6316
Fix RuboCop Performance/MapCompact
offenses
...
- Rename an iterator variable since it would make the line too long.
2024-02-25 22:59:59 +00:00
Markus Reiter
b29a2cdff3
Add missing local variable.
...
Co-authored-by: Bo Anderson <mail@boanderson.me>
2024-02-23 17:09:42 +01:00
Markus Reiter
132a87aff5
Rename Tap#repo_var
to Tap#repo_var_suffix
.
2024-02-23 16:02:29 +01:00
Markus Reiter
ab27efbd9d
Make Tap::each
respect the API.
2024-02-22 17:56:47 +01:00
Mike McQuaid
89fd6964f9
Merge pull request #16715 from reitermarkus/tap-ensure-installed
...
Clean up `Tap#ensure_installed!` usage.
2024-02-22 08:47:48 +00:00
Markus Reiter
9f5e1f2870
Clean up Tap#ensure_installed!
usage.
2024-02-21 03:21:02 +01:00
Markus Reiter
771193c80a
Ensure readall
runs without API.
2024-02-20 20:44:14 +01:00
Mike McQuaid
d33efcda9c
Merge pull request #16556 from PauloPhagula/patch-1
...
fix: use recommended way of updating Fish shell $PATH
2024-02-19 14:44:49 +00:00
Sharon Azriel
a1fbbc323a
[update.sh] New test with protection of Homebrew directory
2024-02-13 10:02:18 +02:00
sazriel26
807b3e3394
Update Library/Homebrew/cmd/update.sh
...
https://github.com/Homebrew/brew/pull/16289#discussion_r1448765696
Co-authored-by: Mike McQuaid <mike@mikemcquaid.com>
2024-02-13 10:02:18 +02:00
Sharon Azriel
835762b289
Ready for review?
2024-02-13 10:02:18 +02:00
sazriel26
3d0f543b63
Update Library/Homebrew/cmd/update.sh
...
Remove one empty line?
Co-authored-by: Mike McQuaid <mike@mikemcquaid.com>
2024-02-13 10:02:18 +02:00
Sharon Azriel
d9a38e76a9
Brew style --fix (applied)
2024-02-13 10:02:18 +02:00
Sharon Azriel
4a37e81179
Rewrite of branching tests in parsing URL
2024-02-13 10:02:18 +02:00
Sharon Azriel
2833a217e9
[Library/Homebrew/cmd/update.sh] Add support for token provided w/o user in URL
2024-02-13 10:02:18 +02:00
Sharon Azriel
3619636f7f
[Library/Homebrew/cmd/update.sh] Release Candidate for pull request
2024-02-13 10:02:18 +02:00
Sharon Azriel
53c261814e
Fix brew style on update.sh (2)
2024-02-13 10:02:18 +02:00
Sharon Azriel
02a8de72d6
Fix brew style on update.sh
2024-02-13 10:02:17 +02:00
Sharon Azriel
07287982f2
Fix missing ;
2024-02-13 10:02:17 +02:00
Sharon Azriel
01d1e9b228
New implementation through BASH regexes match
2024-02-13 10:02:17 +02:00
sazriel26
a1e9e93902
Update Library/Homebrew/cmd/update.sh
...
better wording
Co-authored-by: Mike McQuaid <mike@mikemcquaid.com>
2024-02-13 10:02:17 +02:00
Sharon Azriel
154a8c398b
Release Candidate 2
2024-02-13 10:02:17 +02:00
Sharon Azriel
e24027ea57
Release Candidate 1
2024-02-13 10:02:17 +02:00
Sharon Azriel
c83172c8f4
[update.sh] Parse local token in git remote.origin.url config
2024-02-13 10:02:17 +02:00
Markus Reiter
29179e45a1
Refactor rename/migration handling in Formulary
.
2024-02-06 00:52:38 +01:00
Eric Knibbe
e63b1f4da5
docs: monospace suggested values
2024-02-04 15:42:26 +01:00
Paulo Phagula
8ae063acb1
Remove unnecessary pre-setting of PATH
2024-02-04 13:51:45 +01:00
Paulo Phagula
cf4876ac41
Use -P flag to Manipulate $PATH directly.
...
Based on https://github.com/Homebrew/brew/pull/7215
2024-02-04 13:51:45 +01:00
Paulo Phagula
dc4c827a51
fix: use recommended way of updating Fish shell $PATH
...
Akin to https://github.com/Homebrew/brew/pull/11349
2024-02-04 13:51:45 +01:00
Douglas Eichelberger
8156c5d140
Audit remaining commands
2024-01-31 20:02:33 -08:00
Michael Cho
6bc6aae0ca
cmd/upgrade: rename arg to installed_formula/cask
...
This avoids running `brew outdated` in shell completions, which is
noticeably slow.
2024-01-24 12:45:49 -05:00
Mike McQuaid
36024e2a4d
Merge pull request #16506 from MikeMcQuaid/adjust_installfromapimessage
...
cmd/update-report: adjust installfromapimessage.
2024-01-19 19:20:04 +00:00
Issy Long
c63723bd7d
Merge pull request #16501 from issyl0/rubocop-new-rules-style-redundant-freeze
...
Fix RuboCop `Style/RedundantFreeze` offenses
2024-01-19 15:05:08 +00:00
Mike McQuaid
6a8ac2bd0e
cmd/update-report: adjust installfromapimessage.
...
Only warn about `HOMEBREW_NO_INSTALL_FROM_API` and make this a one-time
message.
Fixes #16481
2024-01-19 08:55:03 +00:00
Kevin
5a297a7dd5
Merge pull request #16499 from p-linnane/vendor-install-wording
...
cmd/vendor-install: adjust wording
2024-01-18 21:49:49 -08:00
Issy Long
f682147598
Fix RuboCop Style/RedundantFreeze
offenses
2024-01-18 22:20:01 +00:00
Patrick Linnane
532fdc0f73
cmd/vendor-install: adjust wording
...
Signed-off-by: Patrick Linnane <patrick@linnane.io>
2024-01-18 09:41:19 -08:00
Mike McQuaid
fd9775d512
cmd/vendor-install: fix some elses.
...
The logic in #16495 wasn't quite right.
2024-01-18 17:35:47 +00:00
Mike McQuaid
ebfa93c949
cmd/vendor-install: undocumented option to allow setting processor.
...
This can be useful when testing fetch on a different processor than the
one the user is running on.
While we're here, refactor code run on `source` to need a function call
instead.
2024-01-18 14:38:56 +00:00