24 Commits

Author SHA1 Message Date
XuehaiPan
3f96d963f7 style: fix inconsistent code style for shell scripts 2021-09-15 14:59:01 +08: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
hyuraku
34919c45f2 add comments about ENV 2021-04-20 22:52:07 +09:00
hyuraku
b910cf84b1 shims/mac/super/scm/git: repair style 2021-04-18 18:34:36 +09:00
Markus Reiter
c2c93d1cc9
Run shellcheck on cask utils and shim scripts. 2021-04-02 03:03:54 +02:00
Bo Anderson
d625f91d3c
shims/scm/git: fix unintended backtick usage 2021-03-02 17:07:02 +00:00
Bo Anderson
a3ed481b9e
Revert "Revert "shims/mac/super: add ruby shims to set SDKROOT""
This reverts commit fe992cab2b943269e39e8f9f5830f4983c440e8b.
2021-03-02 17:06:05 +00:00
Mike McQuaid
fe992cab2b
Revert "shims/mac/super: add ruby shims to set SDKROOT" 2021-03-02 15:11:14 +00:00
Bo Anderson
7e75a49b77
shims/mac/super: add ruby shims to set SDKROOT 2021-02-24 12:48:07 +00:00
Mike McQuaid
f8091a4d51
shims/scm: handle missing Subversion on Catalina.
Fixes https://github.com/Homebrew/brew/issues/7781
2020-06-24 10:37:36 +01:00
EricFromCanada
9e4fb40f92 docs: update descriptions of git- and curl-related vars
Note that the `HOMEBREW_FORCE_BREWED_` vars are automatically set if the system `git` and `curl` are too old. Drop mention of `HOMEBREW_GIT` which isn't user-settable.
2018-10-26 23:47:59 -04:00
Mike McQuaid
25249f0114
shims/super/cc: detect High Sierra differently.
Don't rely on `RUBY_PLATFORM`'s kernel version as it's the machine that
Ruby was built on (10.5) for portable ruby.
2018-09-20 13:49:10 +01:00
Xu Cheng
6aa7b47ae1
scm shim: handle edge case
Since #4748 `HOMEBREW_GIT` is set by the `brew.sh`, whose value is default to be `git`.
As a result, it completely bypasses the logic of the shims/scm/git.

This fixes the issue by checking whether `HOMEBREW_GIT` and
`HOMEBREW_SVN` are set to be `git` and `svn` respectively.

Fixes #4825.
2018-09-05 16:01:36 +08:00
Buck Evan
0a2e649f00 type -P is more portable than which
Migrated from https://github.com/Linuxbrew/brew/pull/621
2018-03-18 16:51:22 -07:00
Mike McQuaid
60362605de scm/git: hide prefix cd failure warning.
This may happen with certain checkout configurations (such as on our CI
boxes).

Also, rename the variables to be clearer about what they reference.
2017-12-30 17:36:37 +00:00
ilovezfs
b40484e87c
Revert "Revert "shims/scm/git: Fix the search for brewed git"" 2017-12-23 03:37:27 -08:00
ilovezfs
0dabb464dd
Revert "shims/scm/git: Fix the search for brewed git" 2017-12-21 15:03:40 -08:00
Shaun Jackman
5c7d2d0bb5 shims/scm/git: Fix the search for brewed git
Search for brewed git in both locations:
$HOMEBREW_PREFIX/Homebrew/Library/Homebrew/shims/scm/../../../../../bin/git
$HOMEBREW_PREFIX/Library/Homebrew/shims/scm/../../../../bin/git
2017-12-20 16:24:22 -08:00
Mike McQuaid
8205e61e64 More environment filtering tweaks
- only document HOMEBREW_* variables in the manpage (although still
  read from all the original environment variables).
- resort manpage environment variables in alphabetical order
- check the original path for trailing slashes
2017-05-13 11:42:01 +01:00
Mike McQuaid
be2e6df948 scm/git: more old OS X versions tweaks.
- unset IFS to fix version parsing on older Bashes
- reuse existing HOMEBREW_MACOS_VERSION if it’s available
- set rather than unset popup_stub
2016-10-16 16:11:41 +01:00
Mike McQuaid
7292ad1f1a shims/scm/git: fix on old OS X versions.
On older versions of OS X (i.e. pre-Mavericks) `xcode-select` is not
required to be set when using the CLT. Fix this behaviour so `brew
update` doesn't tell everyone on that configuration to `brew install
git`.
2016-10-16 14:14:23 +01:00
Mike McQuaid
408ac6088f scm/git: make --homebrew=print-path absolute.
This ensures that the output is always a fully-resolved path.
2016-08-25 11:12:22 +01:00
Martin Afanasjew
3d862ef5e2 cmd/vendor-install.sh: fix style inconsistencies 2016-08-08 16:00:12 +02:00
Mike McQuaid
a02be9eea2 ENV: move to new paths. (#507)
Move some stuff formerly in `Library/ENV` around:
- Move `Library/ENV/$XCODE_VERSION` to `Library/Homebrew/env/super` as they are
  all superenv wrappers and all symlinks to the same version. We never needed
  the "separate shims for separate versions" functionality and it just adds
  confusion.
- Move `Library/ENV/pkgconfig` to `Library/Homebrew/env/pkgconfig` to get more
  things under `Library/Homebrew`
- Move `Library/ENV/scm` to `Library/scm` as these wrappers are not actually
  used by or related to superenv (or stdenv) in any way.
2016-07-15 19:03:45 +01:00