ls -hコマンドはmac osx Catalina 10.15.2では機能しません。

ls -hコマンドはmac osx Catalina 10.15.2では機能しません。

私は初心者であり、これは非常に初心者の質問かもしれません(あらかじめご注意ください)。 zshで端末を使用すると、入力はls -h期待される結果を出力しません。代わりls-h。 zshモードでは機能が異なりますかls -h

編集:私の予想される実行結果は、ファイルサイズなどを示すよりls -h読みやすく簡単なバージョンになります。ls -l1.3k

ベストアンサー1

ただ実行しても効果はありませんls -h-hからman ls

-h      When used with the -l option, use unit suffixes: Byte, Kilobyte,
        Megabyte, Gigabyte, Terabyte and Petabyte in order to reduce the
        number of digits to three or less using base 2 for sizes.
...
  -l    (The lowercase letter ``ell''.)  List in long format. (See below.)
...
The Long Format
   If the -l option is given, the following information is displayed for each
   file: file mode, number of links, owner name, group name, number of bytes
   in the file, abbreviated month, day-of-month file was last modified, hour
   file last modified, minute file last modified, and the pathname...

サイズが必要な場合は、次のものが必要ですls -lh

$ /bin/ls -lh .zshrc
-rw-r--r--  1 username  staff   4.6K May 18 18:54 .zshrc

おすすめ記事