5593 Commits

Author SHA1 Message Date
Mike McQuaid
72d25a21df
Merge pull request #15853 from clint-stripe/clint/pass_through_curl_home
Allow HOMEBREW_CURLRC to specify a path for curl `--config`
2023-08-15 11:42:26 +01:00
Clint Harrison
4ade9351e4
Allow HOMEBREW_CURLRC to provide a path for curl --config
Co-authored-by: Mike McQuaid <mike@mikemcquaid.com>
Co-authored-by: Carlo Cabrera <30379873+carlocab@users.noreply.github.com>
2023-08-15 11:29:02 +01:00
Sam Ford
4314daa2cf
python: expand and refactor tests
This brings coverage of `Language::Python::Shebang` to 100%.
2023-08-15 00:53:41 -04:00
Sam Ford
87935f8d0f
perl: expand and refactor tests
This brings coverage of `Language::Perl::Shebang` to 100%.
2023-08-15 00:53:41 -04:00
Sam Ford
d1297c0974
node: add shebang rewriting
Formulae that depend on `node` sometimes contain files that use a
shebang like `#!/usr/bin/env node` and this can lead to issues when
the `node` in a user's environment isn't brewed `node`.

For example, some node modules are compiled when the formula is built
but if the user's `node` is a different major version than brew's
`node`, the differing `NODE_MODULE_VERSION` can produce an error when
certain parts of the application are used. The formula may build and
test fine and the issue may only become apparent when more of the
application is exercised.

This adds a `Language::Node::Shebang` module (borrowing from the
existing Perl and Python examples), which allows us to use
`rewrite_shebang detected_node_shebang, ...` in formulae to address
this type of issue.
2023-08-15 00:53:41 -04:00
Douglas Eichelberger
d01cda2815 Turn up the types 2023-08-12 22:01:22 -07:00
Mike McQuaid
22553cd34a
Fix cask sharding issues
- Fix cask info output being incorrect
- Improve some code referring to casks as formulae
- Move livecheck cask fixtures to not shadow existing names
- Adjust the cask tap symlinking logic to make handling outdated
  shadowed casks significantly easier
- Fix various flaky tests caused by casks sharding logic
- Prefer longer paths when there's multiple formulae or casks in a tap
  with the same name rather than always using the first
2023-08-10 16:08:47 +01:00
Douglas Eichelberger
5d5c22e104 Replace integration test with unit test 2023-08-07 18:32:08 -07:00
Douglas Eichelberger
880362669b Add tests 2023-08-04 16:21:34 -07:00
Mike McQuaid
b3c33d34ab
Various sharding fixes
- Load paths with no API when needed (e.g. for `brew edit`)
- Use no API mode for `brew log` as it's needed there
- Define sharding format for homebrew-cask and homebrew-core inside
  `Tap` methods
- Create new formulae/casks in location defined by these `Tap` methods
- Fix a bug in Formulary that made sharded formulae lookup less
  efficient (and possibly broke it for core and some API usage)
- Fix various other hardcoded Formula/Cask directory assumptions

Co-authored-by: Bo Anderson <mail@boanderson.me>
2023-08-04 16:43:13 +01:00
Eric Knibbe
b3ecd91f97
dev-cmd/edit: suggest tapping core repositories 2023-08-01 13:39:28 -04:00
Branch Vincent
98323cd7e6
python: create venv's --without-pip 2023-07-31 08:51:47 -07:00
Mike McQuaid
4b9c031e1b
Merge pull request #15725 from razvanazamfirei/bump-cask-pr-arch
`bump-cask-pr`: add arch-specific version support
2023-07-25 15:52:36 +01:00
Razvan Azamfirei
33375ae938
rename class and reorganize files 2023-07-25 06:41:38 -04:00
Mike McQuaid
a78173b419
Merge pull request #15746 from apainintheneck/install-cmd-should-upgrade-existing-casks
cmd/install: upgrade already installed casks
2023-07-25 08:21:52 +01:00
Douglas Eichelberger
479ca5e314 Fix test 2023-07-24 07:01:57 -07:00
Douglas Eichelberger
11bb278284 Support Pathname as second arg to gsub! 2023-07-23 21:14:21 -07:00
Douglas Eichelberger
cec3daf6be Fix type regression 2023-07-23 19:48:48 -07:00
apainintheneck
c9dea04bd4 cmd/install: upgrade already installed casks
Previously, the behavior was to warn users that a cask was already
installed and then skip modifying the installed version. This is
different to how we handled things with formulas. For them we would
upgrade any already installed formulas. This just brings casks in line
with what we already do with formulas.

Changes:
- cmd/install: Upgrade already installed casks if HOMEBREW_NO_INSTALL_UPGRADE
  is not set
- env_config: Update wording of HOMEBREW_NO_INSTALL_UPGRADE to include casks
- remove error that was only used to alert about already installed casks

Note:
- The upgrade command for casks defaults to --greedy when you pass named casks
  to the command which means that this will always default to that behavior
  since you must specify the name of the cask when installing.
2023-07-23 18:50:39 -07:00
Razvan Azamfirei
c64c834d05
bump-cask-pr: add arch-specific version support 2023-07-21 11:45:34 -04:00
Branch Vincent
9597f455aa
formula: add std_pip_args 2023-07-19 20:02:47 -07:00
Patrick Linnane
c56669e9cd
various: fix miscellaneous typos 2023-07-18 08:52:49 -07:00
Mike McQuaid
68aa5da833
Merge pull request #15614 from carlocab/quictls-cop
rubocops/lines: disallow `quictls` dependencies in homebrew/core
2023-07-18 10:44:09 +01:00
Carlo Cabrera
451bea2713
tests: add QuicTLSCheck test 2023-07-14 13:13:51 +08:00
Bo Anderson
ba02c669e1
Introduce CoreCaskTap class 2023-07-13 20:33:26 +01:00
Bo Anderson
dc7a47d0ac
test: drop deprecated uses_from_macos_elements checks 2023-07-07 20:35:54 +01:00
Mike McQuaid
7da934f7e2
Deprecate/disable/delete code.
The next release after this is merged will be 4.1.0.

Co-authored-by: Markus Reiter <me@reitermark.us>
2023-07-06 16:56:20 +01:00
Mike McQuaid
229a1f6c1e
Remove Tap#versioned_formula_files
This doesn't work with the API and the single caller can be
refactored to not need it instead.
2023-07-05 16:28:44 +01:00
Bo Anderson
71d51faa55
Introduce tag for implicit dependencies 2023-07-04 13:40:58 +01:00
Bo Anderson
d1b923f314
Introduce UsesFromMacOSDependency
Add Formula#declared_deps and SoftwareSpec#declared_deps
2023-07-04 13:40:55 +01:00
Bo Anderson
53d513695a
Remove TapDependency 2023-07-04 13:31:58 +01:00
William Woodruff
6ec9575c2a
Merge remote-tracking branch 'origin/master' into ww/update-resources-handle-non-pypi-urls 2023-07-03 16:35:05 -04:00
Bo Anderson
dcba7f356d
test/utils/github_spec: fix artifact URL test 2023-07-03 03:31:01 +01:00
William Woodruff
91a9b57d1f
Revert "Revert "PyPI: Handle non-pythonhosted formula URLs""
This reverts commit 286e175a313bfc4505f972c343200dfa7e6afef5.
2023-07-02 20:46:46 -04:00
Mike McQuaid
b3015701f6
dependency: use formula name.
This allows renamed or aliased formulae dependencies to be resolved to
specific formulae correctly and deduplicated.

Fixes #15488
2023-06-29 14:30:43 +01:00
Bo Anderson
6d8b033eff
Significantly improve fetch speed of bottles 2023-06-22 15:08:16 +01:00
Bo Anderson
8dc2e80a98
Significantly improve install speeds with smarter postinstall detection 2023-06-22 03:06:45 +01:00
Razvan Azamfirei
b1baca7720
rephrase failure message 2023-06-20 11:33:49 -04:00
Razvan Azamfirei
c1009247bf
Apply suggestions from code review
Co-authored-by: FX Coudert <fxcoudert@gmail.com>
2023-06-20 08:59:01 -04:00
Razvan Azamfirei
adf6278e3c
rubocops: add emoji audit 2023-06-20 08:10:38 -04:00
hyuraku
de7152b7a3 rename Cask::outdated_versions 2023-06-19 22:09:01 +09:00
Mike McQuaid
75dd070395
Remove Google Analytics
We are now entirely migrated to InfluxDB so can remove all GA code.
2023-06-16 10:33:15 +01:00
Bo Anderson
f504b92c45
Preliminary macOS 14 (Sonoma) support 2023-06-05 23:21:11 +01:00
Mike McQuaid
286e175a31
Revert "PyPI: Handle non-pythonhosted formula URLs" 2023-06-05 17:21:56 +01:00
William Woodruff
7915363482
test: brew style --fix
Signed-off-by: William Woodruff <william@yossarian.net>
2023-06-04 23:33:46 -04:00
William Woodruff
af6f728eb4
utils, test: rewrite PyPI::Package
This rewrites the `Package` class from the ground up
to better accomodate non-PyPI URLs.

The existing APIs are largely preserved, but with
clearer invariants around when they can or can't be used
(e.g., `#pypi_info`).

Signed-off-by: William Woodruff <william@yossarian.net>
2023-06-04 23:32:09 -04:00
William Woodruff
ec0361fd9b
test: add another URL test for update_pypi_url
Signed-off-by: William Woodruff <william@yossarian.net>
2023-06-04 00:01:41 -04:00
Carlo Cabrera
8860d8398f
determine-test-runners: fix test 2023-05-29 23:06:09 +08:00
JBYoshi
97b9b61061
Change permission failure from fatal to warning. 2023-05-26 11:13:23 -05:00
JBYoshi
40352cb2da
Make Homebrew check for App Management permissions before updating apps. 2023-05-24 22:11:16 -05:00