Commit Graph
4284 Commits
Author SHA1 Message Date
Bo AndersonandGitHub befaeba6c5 Merge pull request #12076 from Bo98/bottle-spec-update
Revamp APIs around bottle specifications
2021-09-20 15:22:35 +01:00
Bo Anderson b55498269f Revamp APIs around bottle specifications 2021-09-20 15:02:05 +01:00
Alexander Bayandin fe9a039774 unpack_strategy: add zstd 2021-09-20 14:12:30 +01:00
Daniel NachunandGitHub bfd605096d Merge pull request #12085 from danielnachun/macos_enable_texlive
missing_formula.rb: don't disable texlive
2021-09-18 15:20:38 -07:00
Bo AndersonandGitHub 12d5e70b87 Merge pull request #12086 from Homebrew/cc-bash
shims/super/cc: run in bash shell
2021-09-18 03:56:16 +01:00
Bo Anderson e224006b49 test/bash_spec: ignore cc script 2021-09-18 01:15:52 +01:00
danielnachun 951251e1d8 missing_formula_spec.rb: don't test latex 2021-09-17 11:53:44 -07:00
Bo Anderson c49dc6803b exceptions: set backtrace for FormulaUnreadableError 2021-09-17 00:06:42 +01:00
Mike McQuaid 3e15023269 test/os/mac: fix uses_from_macos_elements tests. 2021-09-14 09:47:00 +01:00
Mike McQuaidandGitHub 1a904af264 Merge pull request #12018 from FnControlOption/upgrade-tsort
upgrade: use topological sort to upgrade formulae
2021-09-12 19:26:22 +01:00
Rylan PolsterandGitHub bf95782ee2 Merge pull request #12019 from valrus/services-plist-add-process-type
Add process_type to service DSL
2021-09-10 21:01:37 -04:00
valrus 698f4a8f69 Add process_type to service DSL
This enables mpd to be run with the "Interactive" value, which avoids
performance issues such as skipping when playing music. See this PR,
where this was done previously:
https://github.com/Homebrew/homebrew-core/pull/19410

The ProcessType plist key was lost in the conversion to the service DSL:
https://github.com/Homebrew/homebrew-core/commit/483ad1fdfa29f10441b5de4386173e68f4b11555
2021-09-09 17:37:49 -07:00
fn ⌃ ⌥ 0c3e49092c upgrade: use topological sort to upgrade formulae 2021-09-09 13:41:50 -07:00
Bo Anderson a0093bd647 test/support/fixtures/bottles: add fixtures for Monterey 2021-09-09 15:28:15 +01:00
Mike McQuaidandGitHub 365e554f67 Revert "rubocops: allow uses_from_macos openssl@3" 2021-09-09 09:16:59 +01:00
Mike McQuaid a6e4e195c1 rubocops/lines: recommend on_os/OS.os? based on context.
Recommend the use of `on_macos` and `on_linux` unless we're in
`def install`, `def post_install` or `test do` in which case recommend
`OS.mac?` and `OS.linux?` instead.
2021-09-08 13:18:07 +01:00
Sam FordandGitHub c4a91cdc95 Merge pull request #11972 from samford/fix-curl_args_options
Curl: Fix #curl_args options
2021-09-07 15:27:25 -04:00
Jonathan ChangandGitHub 87f7db3b7d Merge pull request #11994 from jonchang/openssl3
rubocops: allow uses_from_macos `openssl@3`
2021-09-07 11:52:34 -07:00
Mike McQuaidandGitHub f5a4214a70 Merge pull request #11956 from benpbolton/patch-1
Wrap mac 'brew info' multi-word service command parameters in single quotes
2021-09-07 19:43:06 +01:00
Jonathan Chang d85559876e tests: skip formulae exist check for openssl* 2021-09-07 11:33:27 -07:00
Sam Ford d44979fa67 Curl#curl_args: Fix and refactor options 2021-09-07 14:13:17 -04:00
FnControlOption eb16e10902 messages: record cask installations.
This is used to record installation times and also to determine
whether to display caveats.
2021-09-02 08:44:00 -07:00
Benjamin Bolton 87f5d98923 Add test for multi-word service argument warpping 2021-09-02 09:26:34 -06:00
Mike McQuaidandGitHub 034d4ac82b Merge pull request #11958 from Homebrew/remove_if_os_rubocop
rubocops/lines: remove OS.mac?/OS.linux? check.
2021-09-02 14:07:41 +01:00
Mike McQuaid 227a96fd7f rubocops/lines: remove OS.mac?/OS.linux? check.
This will be reimplemented in https://github.com/Homebrew/brew/pull/11955
but this allows us to merge the homebrew-core changes before that PR is
merged.

Closes https://github.com/Homebrew/brew/pull/11946
2021-09-02 13:50:23 +01:00
Bo Anderson 9e42ddb011 sandbox: fallback to tput for winsize 2021-09-01 21:09:23 +01:00
Benjamin BoltonandGitHub 632b96780f Test for single-quote service wrapper 2021-09-01 11:54:38 -06:00
Rylan Polster 5d536d66fc Rename HOMEBREW_JSON_CORE to HOMEBREW_INSTALL_FROM_API 2021-08-27 00:24:15 -04:00
Rylan PolsterandGitHub 8690d661fd Merge pull request #11859 from Rylan12/cask-json
Allow casks to be installed using the `cask-source` API
2021-08-26 23:58:51 -04:00
Rylan Polster e08d5f113c Make Homebrew::API::Versions#latest_cask_version tests macOS-only 2021-08-26 23:35:33 -04:00
Rylan Polster 186c839525 Fix tests 2021-08-26 23:21:48 -04:00
FnControlOption 326321c1fd cli/parser: allow commands that look like options 2021-08-25 14:34:57 -07:00
Rylan Polster c3a8b3841e Only include differring versions
Move the resetting of `MacOS.version` to an `ensure` block.

Fix the tests by adding a test OS and new fixture that has a
different version for that test OS.
2021-08-25 10:30:38 -04:00
Sam Ford e65c9d02ab PageMatch: Expand #find_versions tests 2021-08-19 16:07:53 -04:00
Sam Ford 26821301e7 livecheck: move url/regex generation into methods 2021-08-17 18:03:40 -04:00
Sam Ford 13b349b4ae Refactor #find_versions parameters in strategies 2021-08-16 12:01:32 -04:00
Rylan Polster c32223a89c Add cask-source API 2021-08-14 01:59:04 -04:00
Sam Ford 7e07010f06 Improve standardization of strategy tests 2021-08-11 19:05:59 -04:00
Sam Ford 56dd89114d Standardize valid strategy block return types
Valid `strategy` block return types currently vary between
strategies. Some only accept a string whereas others accept a string
or array of strings. [`strategy` blocks also accept a `nil` return
(to simplify early returns) but this was already standardized across
strategies.]

While some strategies only identify one version by default (where a
string is an appropriate return type), it could be that a strategy
block identifies more than one version. In this situation, the
strategy would need to be modified to accept (and work with) an
array from a `strategy` block.

Rather than waiting for this to become a problem, this modifies all
strategies to standardize on allowing `strategy` blocks to return a
string or array of strings (even if only one of these is currently
used in practice). Standardizing valid return types helps to further
simplify the mental model for `strategy` blocks and reduce cognitive
load.

This commit extracts related logic from `#find_versions` into
methods like `#versions_from_content`, which is conceptually similar
to `PageMatch#page_matches` (renamed to `#versions_from_content`
for consistency). This allows us to write tests for the related code
without having to make network requests (or stub them) at this point.
In general, this also helps to better align the structure of
strategies and how the various `#find_versions` methods work with
versions.

There's still more planned work to be done here but this is a step
in the right direction.
2021-08-11 19:05:57 -04:00
Bo Anderson 9686ebe355 os/mac/diagnostic: prevent some double diagostic failures 2021-08-11 14:19:22 +01:00
Rylan PolsterandGitHub 90bbe8bb03 Merge pull request #11831 from Rylan12/api-cleanup
Refactor API methods
2021-08-09 12:32:55 -04:00
Rylan Polster ab8aea0652 Fix tests 2021-08-09 11:00:00 -04:00
Connor Mann ed7066c183 Style fix 2021-08-06 22:35:16 -04:00
Connor Mann 1581a29b28 Update tests 2021-08-06 22:34:30 -04:00
Rylan Polster a8c03c1cc6 Restrict HOMEBREW_JSON_CORE use in tests 2021-08-06 11:52:21 -04:00
Rylan Polster b1215800d4 Fix tests 2021-08-06 11:42:55 -04:00
Rylan Polster 2afbd38dde Remove extra comment 2021-08-06 04:35:45 -04:00
Rylan Polster 737dd1654b Refactor API methods 2021-08-06 04:31:27 -04:00
Connor Mann 3dde12c634 Handle only HEAD kegs in to_latest_kegs 2021-08-04 18:51:39 -04:00
Sam Ford a970780851 livecheck: allow nil return from strategy blocks 2021-08-02 18:33:34 -04:00