Carlo Cabrera
da0cd37bd4
brew/brew: add GITHUB_EVENT_PATH
to env allowlist
...
Needed for Homebrew/homebrew-test-bot#922 .
2023-05-17 01:41:58 +08:00
William Woodruff
ce7283ac32
brew: add GITHUB_STEP_SUMMARY
to allowlist
...
Signed-off-by: William Woodruff <william@yossarian.net>
2023-05-02 19:24:14 -04:00
Carlo Cabrera
de95396407
brew: don't filter GITHUB_EVENT_NAME
...
We need this in `test-bot`. See Homebrew/homebrew-test-bot#905 and
Homebrew/homebrew-test-bot#906 .
2023-04-14 20:40:14 +08:00
Carlo Cabrera
6f63be411b
bin/brew: refine generation of HOMEBREW_*
env vars
...
We inherit some variables from the user's environment but prefix them
with `HOMEBREW_`. This is the case for (1) variables documented in the
manpage and also for some (2) variables used internally by `brew`.
We currently treat both types identically, but we should not. In
particular, we allow users to override type (1), but we don't want to do
this for type (2).
This was partially fixed in f4103e5d61526cfbf7f31540ba45ec171adc452e,
but that fix did not go far enough. Some variables that the user should
not be allowed to override can still be overridden.
This change completes the partial fix and refactors the code so that
we're less likely to mistakenly conflate the two types of variables in
the future.
2023-02-15 13:27:02 +08:00
Daniel Bayley
2ff90c3232
Fix HOMEBREW_BAT_CONFIG_PATH
hint
...
`HOMEBREW_BAT_CONFIG_PATH` should respect [`BAT_CONFIG_PATH`](https://github.com/sharkdp/bat#configuration-file ), in the same way that `HOMEBREW_BAT_THEME` [reflects](https://github.com/Homebrew/brew/pull/13385/files#diff-a8ebbe0466e56bdb9c7ebc74d5ffbd383b8c0902fcb5146cb1960e3d69dadeb1R78 ) `BAT_THEME`.
Previous, for context:
https://github.com/Homebrew/brew/pull/7488
https://github.com/Homebrew/brew/pull/11975
https://github.com/Homebrew/brew/pull/13385
2023-02-09 19:24:31 +00:00
Mike McQuaid
4c95e0dc3f
Merge pull request #14181 from kaihowl/fix/nounset
...
fix: allow running bin/brew with SHELLOPTS=nounset
2022-11-29 11:14:44 +00:00
Kai Hoewelmeyer
3e0bb17780
please shellcheck
2022-11-28 19:54:30 +01:00
Kai Hoewelmeyer
a5b29a79e6
and another one
2022-11-28 19:36:03 +01:00
Kai Hoewelmeyer
43c3c59ca4
fix one more
2022-11-28 19:34:20 +01:00
Kai Hoewelmeyer
4d4f476f73
set -u and fix follow up errors
2022-11-28 19:31:28 +01:00
Shivam Mathur
27dd46d6a9
bin/brew: add GITHUB_OUTPUT
2022-11-27 09:06:56 +00:00
Kai Hoewelmeyer
5db5c6e99a
fix: allow running bin/brew with SHELLOPTS=nounset
...
A similar fix is already present on line 6.
2022-11-26 17:41:36 +01:00
Mike McQuaid
2961132e01
tests: fix under GitHub Codespaces.
2022-11-03 16:33:04 +00:00
Mike McQuaid
3fcd62238a
Merge pull request #13595 from MikeMcQuaid/no_homebrew_no_env_filtering
...
bin/brew: remove HOMEBREW_NO_ENV_FILTERING.
2022-08-23 11:21:30 +01:00
Martijn Pieters
e3a67d2220
brew: add XDG_RUNTIME_DIR copy
...
Further support for brew services; `systemctl --user` falls back to
XDG_RUNTIME_DIR if no DBUS daemon is available.
2022-08-11 21:00:38 +01:00
Mike McQuaid
0f54f342e6
bin/brew: remove HOMEBREW_NO_ENV_FILTERING.
...
It's been deprecated for a long time. Add a disabling message to be
nice (that we'll remove in future).
2022-07-22 14:39:21 +01:00
Bo Anderson
fad20859b1
Merge pull request #13594 from MikeMcQuaid/remove_github_actions_homebrew_macos_self_hosted
...
bin/brew: remove GITHUB_ACTIONS_HOMEBREW_MACOS_SELF_HOSTED.
2022-07-22 14:23:15 +01:00
Mike McQuaid
f4103e5d61
bin/brew: never use HOMEBREW_PATH from users.
...
Fixes https://github.com/Homebrew/brew/issues/13548
2022-07-22 10:33:43 +01:00
Mike McQuaid
25364cbe62
bin/brew: remove GITHUB_ACTIONS_HOMEBREW_MACOS_SELF_HOSTED.
...
It has been more than a few days.
2022-07-22 10:31:10 +01:00
danielnachun
5a711decff
bin/brew: add GITHUB_RUN_ATTEMPT
2022-07-21 16:02:04 -07:00
Kid
721a27d68d
dev-cmd/cat: support setting bat theme via environment variable
2022-06-06 08:44:47 +08:00
Carlo Cabrera
f88e376a98
Avoid filtering TERMINFO_DIRS
...
Closes #13248 .
2022-05-12 16:03:35 +08:00
Bo Anderson
97b94a78b4
bin/brew: allow GITHUB_ACTIONS_HOMEBREW_SELF_HOSTED
2021-12-13 23:05:32 +00:00
XuehaiPan
cf7def0c68
style: apply shellcheck autofix
2021-11-08 03:07:25 +00:00
XuehaiPan
1be5e97e82
brew: fail fast when not using bash
2021-09-16 21:20:57 +08:00
XuehaiPan
bd8db0737d
style: fix inconsistent code style for shell scripts
2021-09-16 01:06:19 +08:00
XuehaiPan
c2d5d84b21
Merge remote-tracking branch 'upstream/master' into fix-inconsistent-shell-style
2021-09-16 01:01:49 +08:00
XuehaiPan
954c3596b2
brew: fail fast when not using bash
2021-09-15 17:10:05 +08:00
XuehaiPan
baac35785c
style: do not allow multi-line for statements
2021-09-15 15:00:23 +08:00
XuehaiPan
3f96d963f7
style: fix inconsistent code style for shell scripts
2021-09-15 14:59:01 +08:00
Bo Anderson
a84b13b6e9
bin/brew: actually quiet cd
...
Fixes #11886 .
2021-08-19 13:33:31 +01:00
Sean Molenaar
e660766514
brew: add DBUS_SESSION_BUS_ADDRESS
copy
2021-07-08 10:28:48 +02:00
Dawid Dziurla
ce436791c9
brew: pass GITHUB_ACTIONS_HOMEBREW_MACOS_SELF_HOSTED
2021-06-28 10:50:08 +02:00
Carlo Cabrera
4fb06efe81
Fix TMUX
env variable filtering
...
We currently filter out `TMUX`, but this breaks displaying some caveats.
This also enables an alias I use (and improved by @Rylan12):
brew alias fzp='!id="$(gh pr list -L200 -R github.com/Homebrew/homebrew-core | TMUX=$HOMEBREW_TMUX fzf-tmux -p "90%,50%" --multi | cut -f1)"; [ -n "$id" ] && brew pr-publish --autosquash $id'
2021-05-13 17:05:18 +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
b358ffd440
Apply suggestions from code review
2021-04-15 17:24:17 +01:00
hyuraku
40ec6250bc
bin/brew: repair style
2021-04-16 00:02:13 +09:00
hyuraku
f578673253
add GitHub Actions to explanation
2021-04-13 21:59:55 +09:00
Mike McQuaid
1d0abd5401
Merge pull request #10778 from MikeMcQuaid/deprecate_no_env_filtering
...
Deprecate HOMEBREW_NO_ENV_FILTERING
2021-03-05 11:24:53 +00:00
Mike McQuaid
d3d4abdbb2
Deprecate HOMEBREW_NO_ENV_FILTERING
...
It's undocumented so we don't need to do the full deprecation dance here
but let's give people a bit of a head up.
2021-03-04 08:51:44 +00:00
Bo Anderson
0a4fd2201e
Let bin/brew handle its own exporting
2021-03-02 16:59:57 +00:00
Shaun Jackman
c56681a227
Comment needed changes if HOMEBREW_LIBRARY changes
2020-12-16 14:03:10 -08:00
Mike McQuaid
ac84a4b051
Fix ZSH FPATH handling
...
Don't require it to be exported but shell out to `zsh` instead.
Fixes https://github.com/Homebrew/brew/issues/9387
2020-12-03 16:52:55 +00:00
Mike McQuaid
3002c810be
Improve ZSH completions handling
...
- Only display the completions caveats from the current shell (assuming
it's one of Bash, ZSH or Fish)
- If the completions location isn't in the ZSH `FPATH` then link to the
documentation explaining how to do so.
Fixes https://github.com/Homebrew/brew/issues/8984
2020-11-26 16:08:26 +00:00
JBallin
0a2718bab8
Remove redundant "all"
2020-09-09 11:49:26 -07:00
JBallin
120c2288ca
Improve comment
...
Co-authored-by: Mike McQuaid <mike@mikemcquaid.com>
2020-09-09 11:47:43 -07:00
JBallin
d985f72d40
Replace Whitelist with Allowlist
...
Whitelist is a potentially offensive word.
2020-09-09 11:36:42 -07:00
Markus Reiter
ebd4ce467c
Output GitHub Actions annotations for brew style
.
2020-09-02 16:44:16 +02:00
Mike McQuaid
21d95f306d
bin/brew: allow GITHUB_ACTIONS_HOMEBREW_SELF_HOSTED.
...
Otherwise test-bot will not behave as expected.
2020-08-07 17:14:11 +01:00
Mike McQuaid
80082f8511
bin/brew: only export CI if not set.
...
Also: GitHub Actions already sets it.
2020-08-07 12:47:05 +01:00