# Homebrew Caskを使うとき、「brew cask search」は効かないので「brew search」を使うようにする URL: https://webrandum.net/homebrew-cask-search/ 公開日: 2019-08-15 更新日: 2020-04-12 カテゴリー: 作業効率化 タグ: Homebrew 出典: Webrandum(著者: サイトウ マサカズ) Homebrew Caskでアプリを検索したいとき、古い記事を見ていると`brew cask search`コマンドを使うと書かれてあるのですが、そのコマンドは2018年9月30日に廃止されてしまったようです。 試しにコマンドを実行してみると、下記のような表示が出てしまいます。 ![brew cask searchコマンドの結果](https://webrandum.net/mskz/wp-content/uploads/2019/08/image_1-12.png) ``` Homebrew Cask provides a friendly CLI workflow for the administration of macOS applications distributed as binaries. Commands: --cache display the file used to cache the Cask audit verifies installability of Casks cat dump raw source of the given Cask to the standard output create creates the given Cask and opens it in an editor doctor checks for configuration issues edit edits the given Cask fetch downloads remote application files to local cache home opens the homepage of the given Cask info displays information about the given Cask install installs the given Cask list with no args, lists installed Casks; given installed Casks, lists staged files outdated list the outdated installed Casks reinstall reinstalls the given Cask style checks Cask style using RuboCop uninstall uninstalls the given Cask upgrade upgrades all outdated casks zap zaps all files associated with the given Cask See also "man brew-cask" Error: help does not take arguments. ``` 返ってきた内容を要約すると、「入力されたコマンドが見つからないから、下記一覧内のコマンドを使ってね」という意味になります。 ## brew searchを使う 解決策は`brew search`コマンドを使うことです(ただし、引数を入力しないと通常のHomebrewの一覧のみが表示されてしまいます)。 今回は試しに`brew search visual-studio`と検索してみて、Visual Studio Codeを検索してみます。 コマンドを実行すると、`==> Casks`のあとにHomebrew Caskでインストールできるアプリ一覧が検索されます。 ![brew searchコマンド](https://webrandum.net/mskz/wp-content/uploads/2019/08/image_2-10.png) ### 参考 - [Warning: Calling `brew cask search` is deprecated – Homebrew – Homebrew](https://discourse.brew.sh/t/warning-calling-brew-cask-search-is-deprecated/3036)