1200字范文,内容丰富有趣,写作的好帮手!
1200字范文 > bash 命令输出到文件_如何将命令输出保存到Bash中的文件(又名Linux和macOS终端)...

bash 命令输出到文件_如何将命令输出保存到Bash中的文件(又名Linux和macOS终端)...

时间:2018-11-05 11:02:08

相关推荐

bash 命令输出到文件_如何将命令输出保存到Bash中的文件(又名Linux和macOS终端)...

bash 命令输出到文件

When you run a command at the bash prompt, it normally prints the output of that command directly to the terminal so you can read it immediately. But bash also allows you to “redirect” the output of any command, saving it to a text file so you can review the output later.

当您在bash提示符下运行命令时,通常会将该命令的输出直接打印到终端,以便您可以立即读取。 但是bash还允许您“重定向”任何命令的输出,将其保存到文本文件中,以便以后可以查看输出。

This works in bash on any operating system, from Linux and macOS to Windows 10’s Ubuntu-based bash environment.

从Linux和macOS到Windows 10的基于Ubuntu的bash环境 ,它都可以在bash上的任何操作系统上运行。

选项一:仅将输出重定向到文件 (Option One: Redirect Output to a File Only)

To use bash redirection, you run a command, specify the>or>>operator, and then provide the path of a file you want the output redirected to.

要使用bash重定向,请运行命令,指定

本内容不代表本网观点和政治立场,如有侵犯你的权益请联系我们处理。
网友评论
网友评论仅供其表达个人看法,并不表明网站立场。