MacOSでアプリのバージョンを取得する

提供:MonoBook

macOSでアプリのバージョンを取得するにはmdlsコマンドを使用する。

 $ /usr/bin/mdls -name kMDItemVersion '/Applications/Safari.app'