ubuntu 文件操作

1.新建文件夹:mkdir 文件名

2、删除文件: re -r  文件名

注意:以上两个是新建和删除文件目录 

3.新建文件: touch test.txt

4.删除文件:rm test.txt

4.打开文件:cat test.txt

只显示前几行 :head -2 test.txt

只显示后几行 :tail -2 test.txt

5.查找文件 :find 文件目录 规则 参数   find . -name  “*.py”

猜你喜欢

转载自www.cnblogs.com/-citywall123/p/11520255.html