LoginSignup
22
24

More than 5 years have passed since last update.

dircolorsが見つからないときは

Posted at

lsの色を変えようと思って検索するとdircolorsコマンドを使えという記事がよく出てくるのですが、Macでは標準でこのコマンドはありません。(dircolorsはGNU ls用のコマンドで、Mac標準のlsはFree BSD lsのためのようです)

環境変数のLSCOLORSで色指定することもできるのですが、dircolors-solarizedを使いたかったのでGNU lsをインストールしました。

brew install coreutils
export PATH="$(brew --prefix coreutils)/libexec/gnubin:$PATH"

これで標準のlsがGNU lsに変わり、dircolorsコマンドもインストールされて使えるようになります。

22
24
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
22
24