当前位置:网站首页>6.echo 和重定向
6.echo 和重定向
2022-07-22 11:08:00 【WuJiaYFN】
6 echo 和重定向
一、echo 命令
echo 文字内容
- echo会在终端中显示参数指定的文字、通常会和重定向联合使用
二、重定向 > 和 >>
Linux 允许将命令执行结果 重定向 到一个文件(重定向也可以理解为写入)
将本应显示在终端上的内容 输出/ 追加到指定文件中
注意: > 表示输出,会覆盖文件原来的内容
>> 表示追加,会将内容追加到已有文件的末尾
三、管道 |
- Linux 允许将一个命令的输出可以通过管道作为另一个命令的输入
- 可以理解为现实生活中的管子,管子的一头塞东西进去,另一头取出来,这里的 | 的左右分为两端,左端塞东西(写),右端取东西(读)
常用的管道命令:
more
:分屏显示内容gerp
:在命令执行结果的基础上查询指定的文本
然后按空格键或者 enter键可以分屏显示后面的内容
边栏推荐
- Juc-7.0-thread collaboration countdownlatch
- Wechat applet introduction tutorial learning notes
- Buuctf breakthrough diary 02-- [hctf 2018] warmup1
- [lttng learning journey] - trace control -- advanced
- 重新安装的nvidia显卡驱动
- 水库防汛泄洪抢险应急广播系统建设4G无线广播模式分析
- [lttng learning journey] - before starting
- Wechat applet comprehensive case practice 1
- Makefile心得
- 水库河道应急广播系统解决方案
猜你喜欢
Human stars website collection plan -- Michael kerrisk
Automated test JSON general parser
二分-机器人跳跃问题
Buuctf entry diary -- [nctf2019]fake XML Cookbook
自动化测试Json通用解析器
1.1.2计网——标准化工作机器相关组织,性能指标
Pytorch custom data set loading (label in CSV file)
(6) Vulhub column: apereo CAS 4.x deserialization vulnerability
Buuctf breakthrough diary 02-- [hctf 2018] warmup1
WinAppDriver 自动测试 winform 自动测试的部署
随机推荐
Wechat applet introduction tutorial learning notes - layout basis of UI chapter
source insight打开时闪退的解决办法
Interview shock 67: talk about tcp/ip protocol? And the role of each layer?
Servlet
Buuctf breakthrough diary -- [geek challenge 2019] hardsql1
regular expression
Relationship and difference between session and cookie
隧道调频广播覆盖系统数字选频光纤拉远漏缆覆盖解决方案
Character interception command
1. Virtualization and container technology
C# Winform开发 弹出式输入框 文本框
Script execution mode
cJSON源码阅读笔记
How to do research and development lean demand management well
Nssctf-01-[swpuctf 2021 freshman competition]gift_ F12
关于二分法
WinAppDriver 自动测试 winform 自动测试的部署
Leetcode notes (I) backtracking
HNOI2003-激光炸弹
两台服务器之间拷贝文件-scp方法