お正月あたらしいmacbook 新規でセットアップした
- treeとかそういうのは brew で
- CotEditorとか app store から入れているものは mas で(masコマンド自体もbrewで入る)
- それ以外、Dropboxとかiterm2とかは brew cask で
- defaultsとかの設定も全部shellでやれるようにしていたのでだいぶ楽
新たに、 duti というのをおぼえた。(duti コマンド自体もbrewで入る)
「私は! xmlを! ○○エディタで開きたかったのに! なぜXCodeが立ち上がるの!!! ばかー」とか、「うおお、.sh まちがって開いてなんか実行走っちゃったああ」みたいなのを防げる
こういうのを用意しておいて、諸々セットアップの後に実行
duti -s com.coteditor.CotEditor .txt all duti -s com.coteditor.CotEditor .csv all duti -s com.coteditor.CotEditor .tsv all duti -s com.coteditor.CotEditor .xml all duti -s com.coteditor.CotEditor .html all duti -s com.coteditor.CotEditor .js all duti -s com.coteditor.CotEditor .css all duti -s com.coteditor.CotEditor .sh all duti -s com.coteditor.CotEditor .pl all duti -s com.coteditor.CotEditor .php all duti -s com.coteditor.CotEditor .go all
いまの設定がどうなっているかはこれでわかる
duti -x txt
photoshop入れてるけどpsdファイルもいったんpreviewでみたいなって人も、こういうので快適になる
duti -s com.apple.Preview .pdf all duti -s com.apple.Preview .psd all duti -s com.apple.Preview .png all