通配符
- 通配符 * 代表零个或多个任意字符
- 通配符‘? 代表一个任意字符
- 中括号 [] “ls [0-9a-zA-Z].txt”表示 0-9,a-z,A-Z 区间内的任意.txt 文件
- 大括号 {} “ls {1,2,3}.txt”表示括号内任意.txt 文件
输入输出重定向
- 输出重定向 > (使用时的作用:把 > 左边的内容重写给 > 右边的内容里面)
- 追加重定向 >> (使用时的作用:把 >> 左边的内容追加给 >> 右边的内容里面)
- 错误重定向 2> (使用时的作用:把 2> 左边的错误信息指定输入到 2> 右边的文件里)
- 错误追加重定向 2>>
- 输入重定向 <
[root@localhost ~]
1_heard.txt 1_sorft.txt 1.txt 222 2.txt anaconda-ks.cfg dd dir
[root@localhost ~]
[root@localhost ~]
[root@localhost ~]
-bash: ddddddddd: 未找到命令
[root@localhost ~]
[root@localhost ~]
-bash: ddddddddd: 未找到命令
-bash: ddddddddd: 未找到命令
[root@localhost ~]
[root@localhost ~]
ls: 无法访问aaa.txt: 没有那个文件或目录
1.txt
2.txt
[root@localhost ~]
[root@localhost ~]
ls: 无法访问aaa.txt: 没有那个文件或目录
1.txt
2.txt
ls: 无法访问aaa.txt: 没有那个文件或目录
1.txt
2.txt
[root@localhost ~]
[root@localhost ~]
1.txt
2.txt
[root@localhost ~]
ls: 无法访问aaa.txt: 没有那个文件或目录
[root@localhost ~]
2