apainintheneck
fe83500617
Moved autoremove logic into cleanup.rb and formula.rb
...
Cleanup.rb:
- Added #autoremove method
- #autoremove is called in clean when HOMEBREW_AUTOREMOVE is set
Formula.rb:
- Added #unused_formulae_with_no_dependents and helpers
Removed old autoremove.rb module.
2022-07-14 13:16:26 -07:00
apainintheneck
fa43418bfb
Moved autoremove logic into autoremove.rb
...
This allows us to call that logic internally in other brew
commands instead of having to shell out.
2022-07-13 16:31:41 -07:00
apainintheneck
74f1eca14c
autoremove.rb: moved logic out into formula.rb, and uninstall.rb
...
This allows us to autoremove formulae in the autoremove and
uninstall commands without having to shell out to brew.
2022-07-13 16:28:49 -07:00
Max Eisner
32b68838f9
switch to more flexible shell_prefix arg
2022-07-13 14:47:45 +02:00
Max Eisner
ad5a1a8138
add docs
2022-07-11 15:49:30 +02:00
Max Eisner
e5f2ddf012
add typecheck
2022-07-11 15:21:57 +02:00
Max Eisner
665e68a82f
switch to named args
2022-07-11 15:08:44 +02:00
Max Eisner
1dcfeb5516
fix style
2022-07-10 15:45:07 +02:00
Max Eisner
3483ee72d5
add DSL to generate completions
2022-07-10 15:35:28 +02:00
Rylan Polster
99447bb1c0
OnSystem
: provide ::MacOSAndLinux
and ::MacOSOnly
2022-06-30 12:57:35 -04:00
Rylan Polster
a9e62b9e38
include OnSystem
to define DSL methods
2022-06-29 11:38:55 -04:00
Rylan Polster
b538ce7361
Add OnSystem
module to generate on_*
methods for formulae and casks
2022-06-24 14:37:50 -04:00
Bo Anderson
02164a35db
Use ORIGINAL_PATHS over envs; reject nil PATH
2022-06-17 19:47:57 +01:00
Bo Anderson
e78665f4f7
Replace ENV["HOME"] with Dir.home
2022-06-17 19:47:57 +01:00
Rylan Polster
cff0122fc4
Remove unnecessary HOMEBREW_INSTALL_FROM_API checks
2022-06-15 16:35:50 -04:00
Mike McQuaid
1bb44979ee
Disable and delete code for 3.5.0
...
The next planned release will be 3.5.0 so let's fix things up for there.
2022-05-30 14:59:14 +01:00
EricFromCanada
2fdc70c3bf
desc, search: also search cask descriptions
2022-03-30 11:23:55 -04:00
Mike McQuaid
79891a7103
Update uses of Formula.all
/Cask::Cask.all
...
Add some `--all` flags we'll eventually migrate to to ensure that we'll
eventually require their usage to read all formulae. Where we need to
do stuff later, add some comments.
2022-03-08 19:24:56 +00:00
Mike McQuaid
20f2b14c38
formula: remove OnOS deprecation comment.
...
We can't actually remove this as we still need it indefinitely in e.g. `def caveats`.
2022-02-24 12:32:36 +00:00
Mike McQuaid
7ec6d41a1d
Revert "formula: remove OnOS
."
2022-02-24 12:31:32 +00:00
Mike McQuaid
73951a01fc
formula: remove OnOS
.
2022-02-22 10:19:09 +00:00
Carlo Cabrera
9d85a06f11
formula: also capture meson-log.txt
...
This is the log file generated when using `meson`.
2022-01-18 17:42:40 +08:00
Mike McQuaid
3a709d36b2
Start process to remove Enumerable
from Formula
and Cask::Cask
.
...
This is the first step to address
https://github.com/Homebrew/brew/issues/11292 .
2022-01-03 14:59:10 +00:00
Rylan Polster
2e6b6ab3a2
Fix style
2021-12-24 21:15:21 -05:00
Carlo Cabrera
504dfa8494
Revert "remove on_os from formula"
...
This is causing `post_install` failures. Spotted in
Homebrew/homebrew-core#91763 .
This reverts commit fc7462acd5ffb7cc393d2b56b989e96112ade896.
2021-12-21 20:43:57 +08:00
hyuraku
fc7462acd5
remove on_os from formula
2021-12-20 23:06:42 +09:00
Bo Anderson
00b588068f
formula: add keg_only_reason to formula hash
2021-12-11 23:30:06 +00:00
Sean Molenaar
4cb8afeeef
service: add timer support for systemd
2021-11-30 11:05:11 +01:00
Caleb Xu
97bc320836
std_go_args: accept ldflags as string or Array(string)
2021-11-21 07:02:23 -05:00
Caleb Xu
3f357861aa
formula: allow optional output path in std_go_args
2021-11-21 07:02:22 -05:00
Mike McQuaid
d43555dd75
brew style --fix
2021-11-02 11:16:10 +00:00
Bo Anderson
572c7cd179
formula: make each instance have separate spec references
...
This fixes SoftwareSpec#owner being mixed up if there are multiple formula references.
This in turn fixes --force-bottle not working in some scenarios like `brew reinstall`.
2021-10-26 15:03:33 +01:00
Rylan Polster
0b8032d421
Document HOMEBREW_INSTALL_FROM_API
2021-10-22 12:37:57 -04:00
Bo Anderson
16afcff557
formula: fix error in Formula#specified_path with aliases
2021-09-22 02:08:18 +01:00
Mike McQuaid
a3e652e8d8
Merge pull request #12087 from Rylan12/api-head-install-fixes
...
install: fix `HEAD` installations with `HOMEBREW_INSTALL_FROM_API`
2021-09-21 09:43:33 +01:00
Rylan Polster
e8e1deeb32
Cleanup code and remove unneeded methods
2021-09-21 00:43:30 -04:00
Bo Anderson
59dc0ed652
formula_installer: fix error if a compatible bottle was not found
2021-09-20 20:57:39 +01:00
Bo Anderson
b55498269f
Revamp APIs around bottle specifications
2021-09-20 15:02:05 +01:00
Rylan Polster
50fac1737a
install: fix HEAD
installations with HOMEBREW_INSTALL_FROM_API
2021-09-17 23:46:28 -04:00
Mike McQuaid
b622c36be6
Add, use uses_from_macos_names.
...
This strips e.g. `:build` tags.
2021-09-14 09:48:19 +01:00
Bo Anderson
8dd11e4e4c
Set uses_from_macos_elements in all cases
2021-09-14 04:06:40 +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
Mike McQuaid
7c37a34cca
Merge pull request #11927 from FnControlOption/fetch
...
fetch: fix `--bottle-tag` when unbottled on host system
2021-09-01 16:08:05 +01:00
Rylan Polster
5d536d66fc
Rename HOMEBREW_JSON_CORE
to HOMEBREW_INSTALL_FROM_API
2021-08-27 00:24:15 -04:00
FnControlOption
b9fc4e36f0
fetch: fix --bottle-tag when unbottled on host system
2021-08-26 14:44:53 -07:00
Carlo Cabrera
6f7489e52c
formula: make extract_macho_slice_from
private
...
Based on feedback from #11756 .
2021-08-18 11:51:08 +08:00
Carlo Cabrera
0ae032ad2f
Merge pull request #11756 from carlocab/deuniversalize-machos
...
formula: add `deuniversalize_machos` method
2021-08-18 02:28:34 +08:00
Carlo Cabrera
f20d61df9a
Fix typecheck error
2021-08-17 22:47:08 +08:00
Carlo Cabrera
fa635db8a1
Simplify re-definition of targets
2021-08-17 22:32:52 +08:00
Bo Anderson
e8b82bbe1e
Fix brew style
2021-08-13 13:49:52 +01:00