こんなにすぐにmacOS 13 venturaにアップグレードする予定はなかったのですが、アップグレードされてしまい発生した事象です。
新しいCommand Line Toolsが利用可能
% brew doctor Please note that these warnings are just used to help the Homebrew maintainers with debugging if you file an issue. If everything you use Homebrew for is working fine: please don't worry or file an issue; just ignore this. Thanks! Warning: A newer Command Line Tools release is available. Update them from Software Update in System Preferences or run: softwareupdate --all --install --force If that doesn't show you any updates, run: sudo rm -rf /Library/Developer/CommandLineTools sudo xcode-select --install Alternatively, manually download them from: https://developer.apple.com/download/all/. You should download the Command Line Tools for Xcode 14.1. Warning: Your Command Line Tools (CLT) does not support macOS 13. It is either outdated or was modified. Please update your Command Line Tools (CLT) or delete it if no updates are available. Update them from Software Update in System Preferences or run: softwareupdate --all --install --force If that doesn't show you any updates, run: sudo rm -rf /Library/Developer/CommandLineTools sudo xcode-select --install Alternatively, manually download them from: https://developer.apple.com/download/all/. You should download the Command Line Tools for Xcode 14.1.
警告に書かれている順番にコマンドを実行していきます。
softwareupdateコマンド
softwareupdate --all --install --force
こちらは、記事を書いている時点(2022年10月29日時点)ではアップデートなしとなります。
(いずれは、アップデートできるようになるはずですが、、、)
sudoコマンドで削除→インストール
sudo rm -rf /Library/Developer/CommandLineTools sudo xcode-select --install
こちらを実行してもCommand Line Toolsのバージョンは、14.1にならず。
(インストールはとても時間がかかりますので余裕を持って行ってください。こちらもいずれアップデートできるようになるはずです。。。)
Apple Developerよりダウンロードしてインストール
警告に出力されているURLより「Command Line Tools for Xcode 14.1 Release Candidate 2」をダウンロードしてインストールすると、ようやくバージョンを上げることができました。
私のように思いがけずアップデートしてしまった場合は、Apple Developerより直接ダウンロードしてインストールすることをお勧めします!!
Command Line Toolsのバージョンの確認の方法
以下のコマンドを実行します。
brew --config
すると、諸々情報が出てきますがその中にCLTのバージョンも出力されます。
: : macOS: 13.0-x86_64 CLT: 14.1.0.0.1.1666437224 Xcode: N/A