加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 综合聚焦 > 服务器 > 安全 > 正文

“ – ”是指bash中的stdout吗?

发布时间:2020-12-15 19:01:41 所属栏目:安全 来源:网络整理
导读:“ – ”是bash中stdout的快捷方式吗?如果不是什么意思?例如, wget -q -O - $line stdin怎么样? 感谢致敬! 据我所知,bash没有涉及破折号的使用.它只是许多UNIX命令行实用程序的约定 – 在命令行上代替输入或输出文件名时,作为stdin或stdout的占位符. 编
“ – ”是bash中stdout的快捷方式吗?如果不是什么意思?例如,
wget -q -O - $line

stdin怎么样?

感谢致敬!

据我所知,bash没有涉及破折号的使用.它只是许多UNIX命令行实用程序的约定 – 在命令行上代替输入或输出文件名时,作为stdin或stdout的占位符.

编辑:找到它,此行为在The Open Group Base Specifications的POSIX Utility Syntax Guidelines,§12.2.13中指定:

For utilities that use operands to represent files to be opened for either reading or writing,the ‘-‘ operand should be used only to mean standard input (or standard output when it is clear from context that an output file is being specified).

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读