查看文件

时间:2019-10-22 19:11:52   收藏:0   阅读:83

1. 查看全部

  cat test.txt

2. 查看前几行

   head -n 10 test.txt

3. 查看最后几行

 tail -n 10 test.txt

4.  查看文件大小

    du -h test.txt

5.在文件中查看内容

  grep  "123456"  test.txt

6.查看文件的行数

   wc -l test.txt

7. 分页查看文件

 more test.txt

原文:https://www.cnblogs.com/hapyygril/p/11721735.html

评论(0
© 2014 bubuko.com 版权所有 - 联系我们:wmxa8@hotmail.com
打开技术之扣,分享程序人生!