V2EX = way to explore
V2EX 是一个关于分享和探索的地方
Sign Up Now
For Existing Member  Sign In
datadump
V2EX  ›  macOS

mac 的 ls 没有 Linux 的好用?

  •  
  •   datadump · Aug 24, 2022 · 2218 views
    This topic created in 1353 days ago, the information mentioned may be changed or developed.
    小弟初入 mac ,比如执行:
    ls -l /bin
    ls /bin -l
    这两个 linux 下跑的好好的,但是 mac 第一个可以第二个不行

    貌似 mac 的 ls 乱七八糟的。能不能安装 linux 的 ls 呢?

    感谢大家
    6 replies    2022-08-24 17:39:43 +08:00
    jorneyr
        1
    jorneyr  
       Aug 24, 2022
    安装 exa 代替 ls 吧,整个别名
    datadump
        2
    datadump  
    OP
       Aug 24, 2022
    @jorneyr exa 是最优解决方案吗
    catoncat
        3
    catoncat  
       Aug 24, 2022
    BSD 和 GNU 的区别
    catoncat
        4
    catoncat  
       Aug 24, 2022   ❤️ 1
    brew install coreutils

    export PATH="$(brew --prefix)/opt/coreutils/libexec/gnubin:$PATH"
    catoncat
        5
    catoncat  
       Aug 24, 2022
    @crs0910 #4 哈 换行失败
    datadump
        6
    datadump  
    OP
       Aug 24, 2022
    @crs0910 就是在找这个东东呀,太感谢了
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   1019 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 31ms · UTC 18:57 · PVG 02:57 · LAX 11:57 · JFK 14:57
    ♥ Do have faith in what you're doing.