112 Commits

Author SHA1 Message Date
Bo Anderson
8efce9a9d2
os/mac/diagnostic: check min CLT version on env setup 2021-08-17 18:36:27 +01:00
Bo Anderson
9686ebe355
os/mac/diagnostic: prevent some double diagostic failures 2021-08-11 14:19:22 +01:00
Sam Ford
0752d25125
OS::Mac: Move version methods into ::Version 2021-06-23 09:03:46 -04:00
Mike McQuaid
2395113154
diagnostic: hide some warnings on Apple Silicon.
We don't want to complain about either Intel or ARM installations of
Homebrew in `brew doctor` so check for/allow both.
2021-06-15 11:51:29 +01:00
Bo Anderson
fe52b3a402 os/mac/diagnostic: check SDK version matches the path 2021-02-11 01:19:59 +00:00
Bo Anderson
ec3e078bcb os/mac/diagnostic: always require dev tools on Apple Silicon 2021-02-05 12:26:28 +00:00
Francois-Xavier Coudert
b02acb37c0 Remove warning on ARM 2020-12-24 14:15:03 +01:00
Nick Morgan
77e063d4a6
Fixing xcode-select --switch command line option 2020-12-16 21:33:20 -05:00
Mike McQuaid
3c4d12a5d5
extend/os/mac/diagnostic: add more Xcode/CLT update instructions.
Addresses issue mentioned in #9215.
2020-11-20 13:30:00 +00:00
Mike McQuaid
74264b8582
Big Sur cleanup
Remove `HOMEBREW_BIG_SUR_TESTING` variable as it is no longer needed.
2020-11-18 10:15:53 +00:00
Markus Reiter
f87c9c5dc4 Fix tests failing locally. 2020-11-18 05:54:42 +01:00
Mike McQuaid
5afff3f3aa
Handle macOS Homebrew on ARM
- Output `brew doctor` and `brew install` messages noting this configuration is (currently) unsupported and encourage use of Rosetta instead
- Output Rosetta 2 usage in `brew config` on ARM (whether in Rosetta 2 or not)
- Check the architecture of (newly installed) dependencies and ensure they are using the correct architecture.
- Don't allow installing macOS Intel Homebrew in macOS ARM Homebrew default prefix (and vice versa
- Actually write out the architecture of dependencies to the tab rather than generating and throwing them away
- Set and document the expected default prefix for macOS Intel Homebrew, macOS ARM Homebrew (`/opt/homebrew`) and Homebrew on Linux

While we're here:
- Don't say Big Sur is a prerelease version but still make it clear we
  don't support it (yet).
- Don't reference non-existent IRC channel
2020-11-12 17:06:47 +00:00
Mike McQuaid
6b27dcb11c
workflows/tests: use Big Sur.
Migrate GitHub Actions to Big Sur.
2020-11-06 15:11:33 +00:00
Markus Reiter
24ae318a3d Move type annotations into files. 2020-10-10 14:59:39 +02:00
Mike McQuaid
f161e56ce0 ENV: check SDK exists when setting up.
Reuse code from `brew doctor` that checks and produces a fatal error
and from `install.rb` that runs it.

Closes #8646
2020-09-11 12:05:22 +01:00
Luthaf
3376646b06 Do not suggest use of deprecated brew cask reinstall 2020-09-04 11:37:37 +02:00
Maxim Belkin
a6d29894d9 cleanup: fix and reuse portable ruby logic.
Align the logic in `cleanup_portable_ruby` with that in `ruby.sh`.

Co-authored-by: Maxim Belkin <maxim.belkin@gmail.com>
Co-authored-by: Mike McQuaid <mike@mikemcquaid.com>
2020-09-03 09:43:41 +01:00
Markus Reiter
d50dc2e1bb Refactor and document Homebrew::Diagnostic. 2020-08-14 18:46:43 +02:00
Mike McQuaid
a1dc809f5b
bin/brew: don't filter GitHub Actions variables. 2020-08-07 10:19:00 +01:00
Mike McQuaid
6d9e2d444d
Big Sur fixes
- Make missing SDKs message more clear.
- Always refer to Big Sur as 11.0 (even on Intel).
2020-07-28 16:56:55 +01:00
Mike McQuaid
fa760a2f26
Fix brew style. 2020-07-07 13:12:37 +01:00
Bo Anderson
9297b18aa6 Add SDK availability diagnostic 2020-07-01 16:07:14 +01:00
Mike McQuaid
0ea2c5f15b
os/mac/diagnostic: suggest untapping phinze/cask.
As seen in https://github.com/Homebrew/brew/issues/7605.
2020-05-20 10:05:23 +01:00
Mike McQuaid
2b224a66a5
os/mac/diagnostic: check for deprecated cask taps.
We keep seeing users popping up with these (#7449) so advise an untap.
2020-05-08 09:18:55 +01:00
Mike McQuaid
3381cbf5c7
Use Homebrew::EnvConfig. 2020-04-07 09:58:26 +01:00
Mike McQuaid
e9aba2efb6
Require and provide portable Ruby 2.6.3. 2019-10-10 15:53:16 +01:00
Mike McQuaid
cf34e1bec8
os/mac/diagnostic: allow Ruby 2.6.3 on Catalina. 2019-10-08 17:17:28 +01:00
Mike McQuaid
b567ed738e Remove Azure Pipelines CI. 2019-08-20 08:48:32 +01:00
Mike McQuaid
e1c00f2358
os/mac/diagnostic: allow use of GitHub Actions CI.
We will be migrating Homebrew/brew to use this in the near future.
2019-08-15 20:45:48 +01:00
Mike McQuaid
bc3a4c1897
diagnostic: tweak frozen string handling. 2019-04-23 23:05:28 -07:00
follower
2064b30fce
Fix check_for_unsupported_macos() on outdated releases
Recent commit 36dbad3922 to default to frozen string literals (via `frozen_string_literal`) broke `check_for_unsupported_macos()` on outdated releases--due to attempted modification of a frozen string literal.

This breaks `install` and `doctor`.

It's like the change wasn't tested on an unsupported outdated release or something... :D

Adding a `+` prefix is apparently one way around this issue according to https://stackoverflow.com/questions/37799296/what-does-the-comment-frozen-string-literal-true-do#37799399. The change worked for me.
2019-04-24 15:02:13 +12:00
Mike McQuaid
36dbad3922
Add frozen_string_literal to all files. 2019-04-20 13:27:36 +09:00
EricFromCanada
15c38a2d8b formatting fixes 2019-04-13 21:29:32 -04:00
EricFromCanada
fa6404e0f5 grammar fixes 2019-04-13 21:29:32 -04:00
Mike McQuaid
e095da4d01
rubocop: enable Layout/EmptyLineAfterGuardClause. 2019-02-21 12:55:49 +00:00
Mike McQuaid
9b5ab7fbb7
Merge pull request #5598 from MikeMcQuaid/odeprecated-odisabled
Update deprecations and cleanup
2019-01-27 12:13:26 +00:00
Mike McQuaid
ce9856efca
os/mac/diagnostic: detect Bitdefender.
This has caused us multiple hard-to-diagnose issues so let's complain
about it in `brew doctor`.
2019-01-25 20:16:35 +00:00
Mike McQuaid
eed1444d61
Update deprecations and cleanup
- Move `odeprecated` to `odisabled`
- Remove `odisabled`
- Enable automatic cleanup on install/reinstall/upgrade.
2019-01-23 21:57:40 +00:00
Mike McQuaid
589ed8e17c
Tweak diagnostic checks
- Make `gist-logs` perform more checks
- Don't complain about a non-/usr/local install at install time unless
  actually building from source.
- Show more checks output on a build error
- Improve naming of checks methods
2019-01-21 19:23:31 +00:00
Mike McQuaid
3a0e0dca36
Output more warnings on unsupported configurations 2019-01-21 13:58:03 +00:00
Mike McQuaid
c3a46bc570
os/mac/diagnostic: remove some old/unneeded checks. 2019-01-21 12:40:12 +00:00
Mike McQuaid
e10d61b81b
Merge pull request #5447 from jonchang/linux-doctor
doctor: check supported versions of glibc and kernel [Linux]
2019-01-02 19:11:05 +00:00
Jonathan Chang
9db92a0203
Revert "Revert "diagnostic: share prefix check"" 2019-01-01 18:11:59 -08:00
Jonathan Chang
c32283e5be diagnostic: use universal pull request message 2019-01-01 15:48:00 -08:00
Mike McQuaid
61fa59e95b
Remove Travis CI specific code
We’re no longer using this for our CI so this is no longer necessary.

Also, migrate `brew tap-new` to use Azure pipelines.
2018-12-30 21:13:24 +00:00
Jonathan Chang
0a5fed1938
Revert "diagnostic: share prefix check" 2018-12-29 14:31:39 -08:00
Jonathan Chang
0d0eac8078 diagnostic: share prefix check 2018-12-27 11:23:18 -08:00
Mike McQuaid
6c49c878cd
os/mac/diagnostic: output non-default Xcode prefix.
This should help people find it when this is a fatal error (and they
don't look at `brew config`).
2018-11-28 14:25:36 +00:00
EricFromCanada
81e2fbd032 docs: update instructions for OS X < 10.9 2018-11-14 16:44:35 -05:00
Mike McQuaid
566b5b45ef
os/mac/diagnostic: don't complain about Xcode version on Azure.
It hasn't been updated yet and we want to be able to update the Xcode
versions for everyone else.
2018-09-30 11:10:19 +01:00