5034 Commits

Author SHA1 Message Date
Dustin Rodrigues
b776fb32de
change includecount to include_count for readability 2023-03-20 07:23:17 -04:00
Dustin Rodrigues
e5fba88035
use includecount argument in pluralize 2023-03-19 23:35:47 -04:00
Mike McQuaid
62edc3258a
cmd/postgresql-upgrade-database: import from homebrew/core.
This is useful for non-contributor users but won't be installed if they
don't have homebrew/core tapped (the default).

Co-authored-by: Rylan Polster <rslpolster@gmail.com>
2023-03-15 13:16:40 -04:00
Mike McQuaid
b61bf2591b
cmd/{rb,nod}env-sync: add new commands.
Add these commands to ease use of Homebrew's bottles with `rbenv` and
`nodenv`.

I've had a lot of people request this over the years and it's worked
well for me for a long time.

I could see people extending these to support other languages or version
managers so perhaps we want a more generic name.

Co-authored-by: Rylan Polster <rslpolster@gmail.com>
2023-03-15 13:13:09 -04:00
Mike McQuaid
296c5088aa
Merge pull request #14935 from hyuraku/move-cask/cmd/uninstall
Move cask/cmd/uninstall
2023-03-13 10:19:41 +00:00
hyuraku
da6f48dbd0
Merge branch 'master' into move-cask/cmd/uninstall 2023-03-12 11:49:06 +09:00
Douglas Eichelberger
1943132cf6 Move i18n out of global 2023-03-11 17:27:53 -08:00
Issy Long
e9d994622e
rubocop: Drop "f" from Naming/MethodParameterName allowlist
- This either stands for "file" but more often than not "formula".
2023-03-11 00:17:27 +00:00
hyuraku
db328b59f2 move cask/cmd/uninstall to cask/uninstall 2023-03-09 22:33:29 +09:00
hyuraku
869c8effb5 remocve Cask::Upgrade::OPTIONS 2023-03-09 20:41:26 +09:00
hyuraku
19f83ef67f move cask/cmd/upgrade to cask/upgrade 2023-03-09 20:40:20 +09:00
Issy Long
a3211f4d7f
rubocop: Drop "d" from Naming/MethodParameterName allowlist 2023-03-08 14:42:57 +00:00
Issy Long
e273c25be0
rubocop: Drop "p" from Naming/MethodParameterName allowlist
- It's used to refer to a patch, so use the long name.
2023-03-08 14:42:56 +00:00
Issy Long
0cd616bc66
rubocop: Drop "r" from Naming/MethodParameterName allowlist
- This stands for "resource" in our case, so use the long name.
2023-03-08 14:42:55 +00:00
Douglas Eichelberger
54fad14ff3 Fix module_function errors 2023-03-06 15:11:10 -08:00
Douglas Eichelberger
1c44a8861d Fix type errors 2023-03-06 15:03:19 -08:00
Douglas Eichelberger
d56e2884aa Enable typing in cmd/ 2023-03-06 15:01:08 -08:00
Douglas Eichelberger
396954c3a8 Initialize lvars as empty arrays 2023-03-06 13:40:04 -08:00
Douglas Eichelberger
e57e50f228 Fix undefined error in update-report 2023-03-06 13:40:04 -08:00
hyuraku
ed2c1d3716 repair cmd/uninstall with zap option 2023-03-06 22:27:53 +09:00
Mike McQuaid
5689065c9e
Merge pull request #14880 from dduugg/fix--env
Fix type error in brew --env
2023-03-06 12:33:11 +00:00
Issy Long
6a704f2f40
sorbet: Bump more files to typed: true
- This was done through the `brew typecheck --suggest-typed --update`
  command.
2023-03-05 18:18:59 +00:00
Mike McQuaid
8051e8818a
Merge pull request #14866 from MikeMcQuaid/update-report-all-formulae-api 2023-03-05 08:10:57 +00:00
Douglas Eichelberger
b7d2953412 enable typing in --env 2023-03-03 19:12:33 -08:00
Douglas Eichelberger
e63111a7b5 resolve type error in --env 2023-03-03 18:41:19 -08:00
Mike McQuaid
8c333f4ec6
Merge pull request #14851 from hyuraku/move-cask/cmd/list-to-cask/list
Move `cask/cmd/list` to `cask/list`
2023-03-03 09:26:01 +00:00
Mike McQuaid
c2cf0e6f65
Merge pull request #14862 from carlocab/fsmonitor
cmd/update.sh: limit setting `core.fsmonitor` to `false`
2023-03-03 09:11:51 +00:00
Mike McQuaid
26182fd67a
Note that brew update will only report all without API.
It's not worth supporting this option any longer given the API
constraints.
2023-03-03 08:51:58 +00:00
Douglas Eichelberger
0384b82adc
Merge pull request #14826 from dduugg/no-open-struct
Enable Style/OpenStructUse cop
2023-03-02 12:30:28 -08:00
Mike McQuaid
62ee6faa58
Merge pull request #14802 from MikeMcQuaid/update_report_handle_formula_names
Show New/Deleted Formulae/Casks from `brew update`
2023-03-02 14:16:13 +00:00
hyuraku
e39232313f move cask/cmd/list to cask/list 2023-03-02 21:53:15 +09:00
Carlo Cabrera
a29939e8ed
cmd/update.sh: limit setting core.fsmonitor to false
We set `core.fsmonitor` to `false` in #13586 because Git's fsmonitor
daemon prevented the release of our locks, resulting in errors for some
users reported in #13521.

However, the fix from #13586 set `core.fsmonitor` to `false` too often.
This is not needed for taps, or when `HOMEBREW_REPOSITORY` is different
from `HOMEBREW_PREFIX`. The issue in #13521 stems from the fsmonitor
daemon preventing the release of our locks, so there is no need to
prevent the daemon from monitoring repositories that don't contain our
lock files.
2023-03-02 14:04:31 +08:00
Mike McQuaid
9296db0c41
Merge pull request #14839 from hyuraku/move-cask/cmd/info-to-cask/info
Move `cask/cmd/info` to `cask/info`
2023-03-01 12:25:26 +00:00
Douglas Eichelberger
719f1d6c6e Refactor some use of OpenStruct 2023-02-28 13:05:43 -08:00
Mike McQuaid
2451d017f9
update-report: allow additions/deletions from the API.
If we're installing from the API: we cannot use Git to check for differences in
packages so instead use `{formula,cask}_names.txt` to do so.

The first time this runs: we won't yet have a base state
(`{formula,cask}_names.before.txt`) to compare against so we don't output
anything and just copy the files for next time.
2023-02-28 16:46:44 +00:00
hyuraku
efdef5f26c move cask/cmd/info to cask/info 2023-03-01 00:00:54 +09:00
Carlo Cabrera
1201f18db0
Merge pull request #14667 from carlocab/update-reset-tap-names
cmd/update-reset: improve arg parsing
2023-02-28 22:05:10 +08:00
Carlo Cabrera
53053e0625
cmd/update-reset: improve arg validation
This is based on feedback from #14667.
2023-02-28 20:38:00 +08:00
Carlo Cabrera
12364d70d2
Revert "cmd/update-reset: accept tap names as arguments"
This reverts commit ac7dbc008284e1a85353548eb8e15c008be902ec.
2023-02-28 20:30:40 +08:00
Douglas Eichelberger
2073e70696 brew style --fix 2023-02-27 21:43:10 -08:00
Douglas Eichelberger
f9f73f3ef6 Tidy up 2023-02-27 21:42:47 -08:00
Douglas Eichelberger
1ab278f74c Fix style/type violations 2023-02-27 20:34:07 -08:00
Douglas Eichelberger
0eccc0e987 git grep -l Utils::Inflection | xargs gsed -i 's|Utils::Inflection|Utils|g' 2023-02-27 20:18:27 -08:00
Douglas Eichelberger
3da68651e5 Port more call sites 2023-02-27 20:18:08 -08:00
Douglas Eichelberger
eb2b990575 Port more call sites 2023-02-27 20:17:33 -08:00
Bo Anderson
e86a8c2477
Move HOMEBREW_NO_INSTALL_FROM_API defaults to shell 2023-02-24 21:53:08 +00:00
Mike McQuaid
f284c662de
Merge pull request #14800 from MikeMcQuaid/cleanup_formula_cask_json
Fix references to `formula.json` and `cask.json`
2023-02-24 17:00:37 +00:00
Mike McQuaid
c209c0403d
Fix references to formula.json and cask.json
These would be stranded after `formula.jws.json`.
2023-02-24 16:46:15 +00:00
Mike McQuaid
4ef8632687
cmd/info: handle casks with API.
Fall back to default location.
2023-02-24 15:44:53 +00:00
Mike McQuaid
f280ce069b
Support loading formulae/casks from subdirectories
Previously, we required all formulae and casks to be in a specific
formula or cask directory but did not check any subdirectories.

This commit allows using subdirectories for official taps, the only
ones likely to be big enough to warrant sharding in this way and to
avoid potentially breaking backwards compatibility for existing taps.

This was inspired by the most recent issues with homebrew-cask.
2023-02-24 10:57:41 +00:00