2426 Commits

Author SHA1 Message Date
Mike McQuaid
b914411ac8
Delete Bintray code
Remove all code related to Bintray. It no longer works so there's no
point keeping it around.

Some of this could arguably be deprecated/disabled first/instead but:
I'm not sure I see the sense in keeping stuff around that's known to be
broken.
2021-05-12 13:37:18 +01:00
Rylan Polster
5f781770b4
Extract Keg::text_matches_in_file from bottle command 2021-05-11 14:26:14 -04:00
Rylan Polster
fe7f80f647
Refactor out and correctly create path regex 2021-05-11 14:26:14 -04:00
Rylan Polster
fd3730a531
bottle: allow links to pkgconfig directory in HOMEBREW_REPOSITORY 2021-05-11 14:26:14 -04:00
Rylan Polster
9ddb531249
bottle: update keg_contain? to match correctly 2021-05-11 14:26:14 -04:00
Nanda H Krishna
8e1c9234e3
dev-cmd/bump: fix empty array check 2021-05-09 18:07:33 +05:30
Rylan Polster
acebeab9cb
bottle: improve style of rebuild fallback
Co-authored-by: Mike McQuaid <mike@mikemcquaid.com>
2021-05-05 08:27:58 -04:00
Rylan Polster
da27c70323
bottle: properly set rebuild for new formulae 2021-05-04 23:10:40 -04:00
Nanda H Krishna
0ed2f6423f
Merge pull request #11308 from nandahkrishna/rename-brew-man
Rename `brew man` to `brew generate-manpages`
2021-05-04 23:02:39 +05:30
Mike McQuaid
7c52c30312
Merge pull request #11293 from bluelabsio/latest-version-only
bottle: Only consider latest rebuild
2021-05-04 17:01:34 +01:00
Chris Wegrzyn
aa3e623b28 Omit warning, as brew audit already covers this 2021-05-04 09:50:42 -04:00
Chris Wegrzyn
570b62dd75 prev_f -> upstream_f 2021-05-04 09:41:53 -04:00
Bo Anderson
f174d4363f
extend/pathname: limit write override to a refinement 2021-05-04 14:20:20 +01:00
Nanda H Krishna
ca11dc92ca
dev-cmd/generate-man-completions: update description
Co-authored-by: Rylan Polster <rslpolster@gmail.com>
2021-05-04 18:38:55 +05:30
Nanda H Krishna
b9b83edc1a
dev-cmd: rename brew man to brew generate-man-completions 2021-05-04 18:32:42 +05:30
Chris Wegrzyn
9ab44b8b6a bottle: just check origin/HEAD for rebuild 2021-05-03 10:07:30 -04:00
Chris Wegrzyn
056c9bb37f Only consider latest rebuild 2021-05-03 10:07:29 -04:00
Mike McQuaid
08926fb1ec
dev-cmd: run Homebrew.install_bundler_gems! earlier.
Run `Homebrew.install_bundler_gems!` a bit earlier for some developer
commands to avoid printing gem installation output in the middle of
normal developer command output.
2021-04-30 12:00:28 +01:00
Mike McQuaid
2fa973bb3b
Merge pull request #11259 from bluelabsio/bottle-root-url-specs
dev-cmd/bottle: Support adding root_url specs to bottle spec
2021-04-29 19:54:53 +01:00
Chris Wegrzyn
68852c9162 Style fix 2021-04-29 12:51:15 -04:00
Chris Wegrzyn
ee8dc058d8 Better help text 2021-04-29 12:37:22 -04:00
Chris Wegrzyn
ffbabfd238 Rename download-strategy to root-url-using 2021-04-29 12:37:20 -04:00
Chris Wegrzyn
76607bbb6f Simplify conditional as suggested
Co-authored-by: Mike McQuaid <mike@mikemcquaid.com>
2021-04-29 12:35:50 -04:00
Chris Wegrzyn
3f60c95425 --download-strategy instead of --root-url-spec 2021-04-29 12:35:48 -04:00
Chris Wegrzyn
4025dce097 Support adding root_url specs in bottle output 2021-04-29 12:34:03 -04:00
Mike McQuaid
dcf03173e9
dev-cmd/bottle: remove double [tag].
Fixes https://github.com/Homebrew/brew/pull/11283#discussion_r623181245
2021-04-29 17:08:23 +01:00
Mike McQuaid
7ba634ccb4
Merge pull request #11283 from MikeMcQuaid/no_bottle_changes_error_handling
dev-cmd/bottle: handle empty collector tags.
2021-04-29 16:32:35 +01:00
Michka Popoff
1a27e4fd4a
Merge pull request #11278 from iMichka/bottle
bottle: do not fail on missing bottle block
2021-04-29 17:22:39 +02:00
Mike McQuaid
f9589429d6
dev-cmd/bottle: handle empty collector tags.
Fixes https://github.com/Homebrew/homebrew-core/runs/2467738434?check_suite_focus=true#step:6:458
2021-04-29 16:00:22 +01:00
Mike McQuaid
d44d686cd5
dev-cmd: avoid uploading identical bottles.
If the `rebuild`, `root_url`, `cellar` and checksums are all identical
between an old and new bottle block: we don't need a new bottle at
all. Handle this by deleting the relevant files with
`brew bottle --merge --write` and gracefully notifying the caller of
`brew pr-upload`.

This should avoid e.g.
39340a11ea
occurring in future.
2021-04-29 14:48:45 +01:00
Michka Popoff
697edce654
bottle: do not fail on missing bottle block
For :all bottle blocks in linuxbrew-core, we are going to remove the bottle
block completely before rebottling.
In linuxbrew-core, we use --keep-old to keep the macOS sha lines.

I am not sure why this exception was written initially, but it
now prevents bottling these formulae, because we have no bottle block
and use --keep-old.

I think it's safe to just skip this check, when there is no bottle block
the old_checksum can just directly return nil.
2021-04-29 14:45:47 +02:00
Bo Anderson
a038110115
dev-cmd/bottle: fix all JSON filename 2021-04-28 22:38:06 +01:00
Mike McQuaid
40a36e422e
dev-cmd/bottle: output more filenames when verbose.
More debugging for the bottle rebuild workflow.
2021-04-28 20:25:02 +01:00
Mike McQuaid
16d5472e4b
dev-cmd/bottle: improve filename handling.
Rely more heavily on the `Bottle::Filename` class rather than hacking
around things manually.

Without this the rebuilding bottles workflow is broken for `all:`
bottles.
2021-04-28 17:10:46 +01:00
Mike McQuaid
20eeb5aca0
dev-cmd/bottle: add missing verbose puts.
These were added but didn't actually output anything...
2021-04-28 14:23:09 +01:00
Mike McQuaid
dd201a219c
dev-cmd: add more --verbose bottle, pr-upload output.
This should make it easier to debug `all:` bottle upload failures.

While we're here, remove the weird `_` that ended up at the end of a
method name.
2021-04-28 12:48:24 +01:00
Mike McQuaid
9680801712
Merge pull request #11256 from dtrodrigues/man-prof-silicon
Allow man and prof Apple Silicon
2021-04-27 15:06:43 +01:00
Mike McQuaid
af1e39797d
Merge pull request #11253 from Bo98/gnu-tar
dev-cmd/bottle: use gnu-tar universally, sort entries & use PAX
2021-04-27 14:37:27 +01:00
Bo Anderson
b0cef64c53
dev-cmd/bottle: use gnu-tar universally, sort entries & use PAX 2021-04-27 14:15:17 +01:00
Dustin Rodrigues
68246e48c7
prof: allow to run on Apple Silicon 2021-04-27 00:09:45 -04:00
Dustin Rodrigues
1781f01d28
man: allow to run on Apple Silicon 2021-04-27 00:09:31 -04:00
Misty De Méo
1978f4be65 Unbottled: fix use of invalid argument 2021-04-26 11:44:35 -07:00
Mike McQuaid
a10f436120
dev-cmd/bottle: tweak tar and tar arguments.
Instead of using `libarchive` on macOS (which has a non-zero dependency
tree) let's instead use `gnu-tar` because:

- it has no dependencies
- we're already using it on Linux

I tested this locally with `ack` (which was getting reproducible bottles
with system and Homebrew `libarchive`) and saw a different checksum. A
quick read of the `gtar` manpage indicated that it uses a GNU tar format
by default which can be made consistent with BSD and GNU tar by using
`--format=ustar` with both. Once this is done, the checksums are the
same. This will hopefully ease the transition to having `all:` bottles
be consistent on Linux, too, which will be useful when homebrew-core is
fully merged/supporting Linux.
2021-04-26 14:42:09 +01:00
Mike McQuaid
5b858ee783
dev-cmd/pr-upload: fix json_files handling.
Another failure:
https://github.com/Homebrew/homebrew-core/pull/75299#issuecomment-825654120
2021-04-23 14:35:26 +01:00
Mike McQuaid
1c7fe79968
dev-cmd/pr-upload: fix bad args reference.
Currently breaking CI.
2021-04-23 13:53:43 +01:00
Mike McQuaid
e8caa61672
Merge pull request #11215 from MikeMcQuaid/pr_upload_bottle_all
dev-cmd/{bottle,pr-upload}: generate, upload `all: $SHA256` bottles.
2021-04-23 12:59:47 +01:00
Mike McQuaid
7af68d0f8e
Fix shellcheck failures
A new version of `shellcheck` (I think?) brought us so new warnings and
errors.

To fix:
- pass `--source-path` so we don't need to stop `shellcheck` trying to
  read sourced files every time
- disable some more warnings/errors we don't care about fixing
2021-04-22 13:18:44 +01:00
Mike McQuaid
521d6b51a6
dev-cmd/{bottle,pr-upload}: generate, upload all: $SHA256 bottles.
Generate `all: $SHA256` bottles if:
- all generated bottles have the same cellar
- all generated bottles have the same checksum

In this case, on `brew bottle --merge --write`: delete all the non-`all`
bottles (and their JSON) and upload only the single one that's
necessary.
2021-04-21 17:10:05 +01:00
Mike McQuaid
965dbaa172
dev-cmd/bottle: fix libarchive installed check.
Used now-removed old method name.
2021-04-21 11:39:19 +01:00
Mike McQuaid
4a3fc2a8fc
dev-cmd/bottle: set uid/gid, use libarchive on macOS.
Take 2 on #11165 but use newish `libarchive` consistently on macOS.
2021-04-21 10:09:35 +01:00