EricFromCanada
bcdb0c7698
upgrade: show upgradeable dependents during dry run
2020-11-17 18:26:35 -05:00
Markus Reiter
9f458142b7
Merge pull request #9146 from reitermarkus/upgrade
...
Mention `--greedy` when no casks were upgraded.
2020-11-16 22:03:10 +01:00
Markus Reiter
3ee66d8c0d
Add type annotations related to upgrade.
2020-11-16 19:45:15 +01:00
EricFromCanada
72bc057014
manpage: fixes for formatting
2020-11-16 08:02:50 -05:00
Markus Reiter
da9289eff0
Add more type signatures.
2020-11-13 12:26:36 +01:00
Mike McQuaid
0606c9fd82
outdated/upgrade: fix upgrade alias edge case.
...
If you're going to follow an alias to find the outdated formula then
ensure that the latest one isn't already installed.
Fixes https://github.com/Homebrew/homebrew-core/issues/63971
2020-11-05 20:33:51 +00:00
Markus Reiter
24ae318a3d
Move type annotations into files.
2020-10-10 14:59:39 +02:00
Markus Reiter
e117a68f42
Force brew upgrade
to treat arguments as casks if --cask
is passed.
2020-10-08 13:43:15 +02:00
Markus Reiter
10e3b63b7b
Inline install
, reinstall
and upgrade
options.
2020-10-08 11:33:38 +02:00
Markus Reiter
7743fed77b
Add “GLOBAL CASK OPTIONS” section to man page.
2020-10-08 11:07:35 +02:00
Markus Reiter
7f14e55f99
Add missing cask options to brew upgrade
.
2020-10-08 11:07:35 +02:00
Markus Reiter
90f145114c
Pass Cask::Config
to Caskroom.casks
.
2020-10-01 01:03:13 +02:00
Mike McQuaid
dbe427073d
Merge pull request #8399 from MLH-Fellowship/migrate-to-args-named
...
args: Migrate usage of args loading methods to args.named
2020-08-25 10:07:27 +01:00
Markus Reiter
4937e4bbc3
Refactor and document Upgrade
.
2020-08-24 19:42:24 +02:00
William Ma
fa7bd3bff6
args: Migrate usage of args loading methods to args.named
2020-08-23 09:02:20 -04:00
Markus Reiter
b48bc316e0
Use CLI::Parser
for cask
commands.
2020-08-13 05:15:15 +02:00
Mike McQuaid
863a0964e2
cmd/upgrade: fix cask/formula args (again).
...
Fixes https://github.com/Homebrew/brew/issues/8228#issuecomment-670161766
2020-08-07 10:25:29 +01:00
Mike McQuaid
3875f16782
Fix --formula and --cask flags.
...
These were all made `--formulae` and `--casks` for consistency but that
doesn't behave as expected because they have special behaviours in
`args`. Instead, use the singular form everywhere.
2020-08-07 09:53:30 +01:00
Mike McQuaid
ced084bd49
Handle casks in commands more consistently.
...
- Ensure the usage documentation always mentions casks when appropriate
- Use --formulae or --casks consistently
- Provide --formulae and --casks switches to upgrade
- Mark more switches as conflicting
2020-08-06 09:25:45 +01:00
Markus Reiter
b1ca2f7e3c
Add shared method for upgrading casks.
2020-08-05 13:55:04 +02:00
Markus Reiter
d4c2ffd705
Refactor CLI::Parser
.
2020-07-31 15:07:17 +02:00
Markus Reiter
c470a6ff43
Pass args
directly to prevent_build_flags
.
2020-07-30 03:21:12 +02:00
Markus Reiter
20bd4280ff
Pass args.cc
to Install
.
2020-07-30 03:21:12 +02:00
Markus Reiter
f8934c0255
Pass args
in Install
and Messages
instead of using global args
.
2020-07-30 03:21:12 +02:00
Markus Reiter
c0d42dd922
Remove --force
from global_options
.
2020-07-28 10:31:11 +02:00
Misty De Meo
f6468ecf00
upgrade: avoid upgrading unrequested casks
...
Fixes #8107 .
2020-07-27 13:25:35 -07:00
Mike McQuaid
2ff56c9e71
Merge pull request #7927 from MLH-Fellowship/integrate-cask
...
Allow references to casks when running upgrade and outdated
2020-07-27 15:11:32 +01:00
Markus Reiter
8a1f8ab858
Pass args
to FormulaInstaller
instead of using global args
.
2020-07-25 04:21:21 +02:00
William Ma
299db98dbf
Fix PR issues
2020-07-16 23:31:26 +10:00
William Ma
ad04284a20
upgrade: Move logic to find outdated formulae into upgrade method
2020-07-16 23:31:26 +10:00
William Ma
210d22e819
Integrate upgrade with cask
2020-07-16 23:31:26 +10:00
Mike McQuaid
2c133a3d45
Check installed dependents on install and reinstall
...
It's not sufficient to do this merely on `brew upgrade` because
`brew install` and `brew reinstall` can also result in formulae being
upgraded.
This requires moving logic from `cmd/upgrade.rb` to `upgrade.rb`. To
save you searching the diff the changes that resulted from doing that:
- Query the installed formulae from class state in `FormulaInstaller`
rather than the (incomplete) list that we passed into it.
- Don't output the "Checking dependents" message. It was there for
systems and configurations where this is slow but for most users
and most installations this will be a (annoying, noisy) no-op.
Fixes https://github.com/Homebrew/brew/issues/7860
2020-07-02 12:53:52 +01:00
Mike McQuaid
e1f3c8d2b3
Merge pull request #7579 from MikeMcQuaid/deprecations
...
Update deprecations
2020-05-23 14:38:10 +01:00
Mike McQuaid
11cf77be17
formula_installer: prelude before fetch.
...
This ensures that dependencies are verified and tapped before they are
fetched. `FormulaInstaller#lock` has been moved into
`FormulaInstaller#install` to avoid locking until necessary.
While we're here, don't compute dependencies before fetching if we're
not going to use them.
2020-05-23 13:40:13 +01:00
Mike McQuaid
4f75a77b08
Update deprecations
...
Add more deprecations, disable deprecations and remove disabled code.
2020-05-18 13:50:46 +01:00
Mike McQuaid
08a9f0e1c0
Use FormulaInstaller#fetch before #prelude.
2020-05-11 09:38:26 +01:00
Michelle Nguyen
2264c08cee
Fetch formula resources before unlinking during upgrade.
...
Fixes #6374 .
2020-05-11 09:37:56 +01:00
Mike McQuaid
4e5c8a35e5
cmd/upgrade: handle nil runtime_dependencies.
...
Fixes #7360
2020-04-15 10:52:48 +01:00
Mike McQuaid
a7fe0ed847
cmd: use more and cleanup new args APIs.
2020-03-05 09:40:15 +00:00
Boris Klimenko
00aa4b7a0b
Apply suggestions from code review
...
Co-Authored-By: Bo Anderson <mail@boanderson.me>
2020-02-26 16:49:48 +03:00
Boris Klimenko
4bde62b651
Apply suggestions from code review
...
Co-Authored-By: Mike McQuaid <mike@mikemcquaid.com>
2020-02-26 15:56:45 +03:00
Boris Klimenko
22375bae7c
Fix style
2020-02-26 13:49:12 +03:00
Boris Klimenko
da5d804bd9
Inline versions of upgraded formulae
2020-02-26 13:42:18 +03:00
Mike McQuaid
ac97c8545a
cmd/upgrade, reinstall: don't install on dry-run.
...
Fixes #7033 .
2020-02-14 12:18:55 +00:00
Samuel Cochran
b922ebec2a
Add --interactive
to brew upgrade
2020-02-06 09:57:49 +11:00
Mike McQuaid
45409618df
cmd/upgrade: fix pinned dependent handling.
...
Ensure they aren't upgraded or reinstalled even if they are outdated.
Fixes #6898 .
2020-01-07 19:38:50 +00:00
Gautham Goli
959b88266d
ARGV: Replace usages of ARGV.resolved_formulae with Homebrew.args
2020-01-02 13:56:19 +00:00
Mike McQuaid
3b2cbf2ffa
upgrade: make dry-run check dependents too.
...
Fixes #6883
2020-01-01 15:04:50 +00:00
Gautham Goli
685a6b4da6
ARGV: Replace usages of ARGV.named with Homebrew.args.named
2019-12-18 20:38:21 +05:30
Bob Lail
a26390be05
Fix bug with printing pinned dependencies.
...
Brew prints this error:
```
Error: undefined method `join' for nil:NilClass
```
because, in this code:
```ruby
puts pinned_dependents.map do |f|
"#{f.full_specified_name} #{f.pkg_version}"
end.join(", ")
```
the block is passed to `puts` and not to `map`. `.join(",")` is called on the output of `puts`.
(I think the regression was introduced in this commit: e12a7b0808353ea81d63774be1edaff81710d7a6)
2019-12-04 12:31:01 -06:00