4907 Commits

Author SHA1 Message Date
vidusheeamoli
67d012afcc search: add separate flag for formulae 2020-03-04 17:58:19 +05:30
Michelle Nguyen(she/her)
352774e80f Add deleted casks to report dump.
Co-Authored-By: Mike McQuaid <mike@mikemcquaid.com>
2020-03-03 13:46:08 -05:00
Michelle Nguyen(she/her)
1f5f9b37c7 Change if statement to elsif.
Co-Authored-By: Mike McQuaid <mike@mikemcquaid.com>
2020-03-03 13:45:46 -05:00
Michelle Nguyen
948ad02c84 Display updated casks when running Already up-to-date.. Fixes #7011. 2020-03-02 17:17:52 -05: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
Dawid Dziurla
f11ddb9aab
log: use user path
Without this, one can't use a custom pager, if it's present in
non-standard PATH, like for example Homebrew on Linux prefix.
2020-02-24 13:26:42 +01:00
Mike McQuaid
8f98b2bcc4
analytics: tweak behaviour.
- Use separate method for `not_this_run?` so we can still set the
  analytics message as seen when set.
- Clarify when analytics message is printed that we haven't sent any
  analytics yet.
2020-02-22 17:13:51 +00:00
Mike McQuaid
e9419e48e5
tap: update docs to note non-shallow default.
Also, while we're here, `rsync` and `git` are not acronyms.
2020-02-19 10:56:44 +00:00
Mike McQuaid
ac97c8545a
cmd/upgrade, reinstall: don't install on dry-run.
Fixes #7033.
2020-02-14 12:18:55 +00:00
Mike McQuaid
1b2bb2380e
Merge pull request #7025 from dawidd6/deps-tree-consistent
deps: give consistent results
2020-02-13 09:43:19 +00:00
Dawid Dziurla
967b9b8112
deps: give consistent results
Co-Authored-By: Mike McQuaid <mike@mikemcquaid.com>
2020-02-12 22:38:20 +01:00
Mike McQuaid
59958777c1
update: allow setting Git name and email.
This is needed for `brew test-bot` when no global Git configuration is
present.
2020-02-12 20:00:14 +00:00
Samuel Cochran
b922ebec2a
Add --interactive to brew upgrade 2020-02-06 09:57:49 +11:00
Samuel Cochran
4c91ca06db
Add --interactive to brew reinstall
More often than I realised, I want to `brew reinstall
--build-from-source --interactive $FORMULA` to add some custom
configuration. It seems like a useful addition?
2020-02-06 09:56:51 +11:00
Mike McQuaid
a915114ea7
tap: fix arguments.
- Use Ruby attribute arguments.
- Fix use of `full_clone` in `cmd/tap` to be on by default.
- Remove unnecessary argument in test.
2020-02-05 20:22:21 +00:00
Mike McQuaid
ecce70bc32
Rename --quieter args to --quiet. 2020-02-05 19:43:59 +00:00
Gautham Goli
1f9563f4bc ARGV: Deprecate ARGV.quieter? 2020-02-04 18:53:33 +02:00
Mike McQuaid
4493f27db2
Merge pull request #6989 from Homebrew/revert-6988-revert-6965-external-help-cli-parser
help: print cli/parser help message if used
2020-02-02 17:51:02 +01:00
Mike McQuaid
8a9dcad2c7
Move more command handling logic to commands.rb. 2020-02-02 17:05:45 +01:00
Mike McQuaid
243e703700
tap: default to full clones.
This makes `Tap` consistent with what the installer is doing.

Generally shallow clones get slower and slower (and more and more
pointless) the more they are fetched so don't make sense for our
use-case.

Keep the option around anyway because it's useful for integration tests.
2020-02-02 16:36:37 +01:00
Issy Long
c65b3f3f13
cmd/gist-logs: Fix bug with parsing of command-line arguments
- A user reported the following error when running `brew gist-logs`,
reproducible with any formula:

```
$ brew gist-logs rustup-init
Error: undefined method `length' for nil:NilClass
Please report this bug:
  https://docs.brew.sh/Troubleshooting
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/cmd/gist-logs.rb:145:in `gist_logs'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/brew.rb:102:in
```

- From what I can tell, `gist_logs_args.parse` had ended up in the wrong
  method. The `gistify_logs` method already has `formula` (ie the
  formula name) passed into it. But it's the `gist_logs` method that needs
  to do the argument parsing. This was discovered by looking at some other
  recently changed ARGV => Homebrew.args code like cmd/info.
2020-01-14 22:13:19 +00:00
Mike McQuaid
2f39057243
Improve handling of *_GIT_REMOTE env vars
- Output a message whenever a non-default remote is set.
- Ensure that `CoreTap.instance.install` uses the right remote.
2020-01-13 09:43:02 +00: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
Mike McQuaid
cfe2f5bfda
Merge remote-tracking branch 'origin/master' into add_change_origin_command 2019-12-30 10:39:28 +00:00
Mike McQuaid
355626ac51
Tweak/fix Git remote configuration behaviour. 2019-12-30 10:38:47 +00:00
EricFromCanada
c31335c46d deps: don't skip those that are both :build and :test
plus a code readability improvement
2019-12-27 17:35:18 -05:00
Gautham Goli
685a6b4da6 ARGV: Replace usages of ARGV.named with Homebrew.args.named 2019-12-18 20:38:21 +05:30
Mike McQuaid
4f732a0170
cmd/info: fix --json argument handling.
`--all` and `--installed` do not require formulae arguments.

Fixes https://github.com/Homebrew/brew/issues/6842
2019-12-16 11:23:55 +00:00
EricFromCanada
aea6d79d21 option parser: check for extra named args 2019-12-15 00:04:45 -05:00
EricFromCanada
0c8eae8d9c command: handle multiple named args 2019-12-15 00:04:45 -05:00
EricFromCanada
90e830c19e cmd: add raises for invalid input 2019-12-15 00:04:45 -05:00
EricFromCanada
2f7c3afeb8 cmd: improve wording of messages, spacing 2019-12-15 00:04:45 -05:00
EricFromCanada
c246207ba0 cmd: updates for command descriptions 2019-12-13 15:24:00 -05:00
EricFromCanada
f0270a585c desc/audit: remove messages obviated by new arg parser 2019-12-13 15:23:38 -05:00
Gautham Goli
22e25dd593 argv: move formulae to cli/args 2019-12-11 16:36:23 +05:30
Mike McQuaid
3f348286f9
cmd/leaves: handle missing formula.
Use `runtime_formula_dependencies` which does this for us.

Fixes #6827.
2019-12-10 15:44:14 +00:00
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
EricFromCanada
9bfd597991 Format debug messages with odebug 2019-12-02 11:33:19 -05:00
EricFromCanada
fcdda8d481 commands: add formatting to headings 2019-12-02 11:32:33 -05:00
hyuraku
e6e0d1128c create new envoronments 2019-12-03 00:45:11 +09:00
Mike McQuaid
766fc4b301
Fix RuboCop 0.77.0 failures. 2019-11-28 15:10:50 +00:00
Mike McQuaid
e8b74601cb
uses: make naming and behaviour consistent with deps and docs. 2019-11-27 12:49:46 +00:00
Mike McQuaid
5cca9b75a8
deps: use runtime_dependencies more readily.
If all the passed packages are currently installed then use
`runtime_dependencies` to get dependency data more quickly and
accurately.

As discussed in https://github.com/Homebrew/brew/issues/6769.
2019-11-27 12:36:21 +00:00
Mike McQuaid
3a9f585ebb
Move more code to utils/analytics. 2019-11-22 09:10:29 +00:00
Issy Long
727f9671c7
info: show Linux formulae details and analytics
- This makes use of the new /api/formula-linux and /api/analytics-linux
  endpoints in formulae.brew.sh to give Linux users up to date formula and
  analytics info for their installed core formulae.

Before, on Linux, the macOS stats for the `ack` formula:

```
$ brew info ack
[...]
==> Analytics
install: 12,422 (30 days), 32,742 (90 days), 97,788 (365 days)
install_on_request: 10,778 (30 days), 28,339 (90 days), 85,202 (365 days)
build_error: 0 (30 days)
```

Now, on Linux, the Linux stats for the `ack` formula:

```
$ brew info ack
[...]
==> Analytics
install: 95 (30 days), 242 (90 days), 737 (365 days)
install_on_request: 94 (30 days), 241 (90 days), 734 (365 days)
build_error: 0 (30 days)
```
2019-11-22 09:10:29 +00:00