我對 Mac OS 完全陌生,我正試圖弄清楚如何在終端中顯示所有echo
命令標誌。當我這樣做時man echo
,它只向我顯示一個標誌,-n
我很確定還有更多標誌。我用谷歌搜索了它,但什麼也沒找到。
先謝謝了!
對於 shell 內置echo
函數,例如,手冊頁沒有提供準確的描述,因為它描述的是二進製文件(通常在 中找到/bin
),而不是內置函數。
有關 Bash 中內置命令的幫助,請使用
help echo
例如,在我的 macOS 版本上,這顯示了我:
echo: echo [-neE] [arg ...] Write arguments to the standard output. Display the ARGs, separated by a single space character and followed by a newline, on the standard output. Options: -n do not append a newline -e enable interpretation of the following backslash escapes -E explicitly suppress interpretation of backslash escapes …
在 zsh 中,最接近的等價物是man zshbuiltins
,它顯示了所有內置命令的文檔。要在其中查找給定命令,請鍵入/ echo
並點擊Return。請注意,/
和之間有多個空格echo
!這不是必需的,但它通常會過濾掉錯誤的命中。
本文收集自互联网,转载请注明来源。
如有侵权,请联系 [email protected] 删除。
我来说两句