上一页 1 ··· 291 292 293 294 295 296 297 298 299 ··· 403 下一页
摘要: 1、测试数据 [root@centos79 test]# ls a.txt b.txt [root@centos79 test]# cat a.txt a1 a2 a3 a4 a5 a6 a7 a8 a9 a10 [root@centos79 test]# cat b.txt b1 b2 b3 b4 阅读全文
posted @ 2021-07-05 00:00 小鲨鱼2018 阅读(174) 评论(0) 推荐(0)
摘要: 1、删除开头的空行 [root@centos79 test]# cat a.txt a g r e i x k like a f g liker a g r e a f g liker [root@centos79 test]# cp a.txt a.txt.bak [root@centos79 t 阅读全文
posted @ 2021-07-04 23:38 小鲨鱼2018 阅读(185) 评论(0) 推荐(0)
摘要: 1、 [root@centos79 test]# echo $a [root@centos79 test]# a=10 [root@centos79 test]# echo $a 10 [root@centos79 test]# unset a ## 清除变量a [root@centos79 tes 阅读全文
posted @ 2021-07-04 23:10 小鲨鱼2018 阅读(125) 评论(0) 推荐(0)
摘要: linux系统中如何删除行首、行尾的空格 1、删除行首空格、制表符 [root@centos79 test]# ls a.txt [root@centos79 test]# cat a.txt a g r e i x k like a f g liker a g r e a f g liker [r 阅读全文
posted @ 2021-07-04 22:56 小鲨鱼2018 阅读(1467) 评论(0) 推荐(0)
摘要: 1、在所有行后添加空行 [root@centos79 test]# cat a.txt a g r e i x k like a f g liker s t 2 a b d s i [root@centos79 test]# awk '{print $0 "\n"}' a.txt a g r e i 阅读全文
posted @ 2021-07-04 22:47 小鲨鱼2018 阅读(841) 评论(0) 推荐(0)
摘要: 1、测试数据如下 [root@centos79 test]# ls a.txt [root@centos79 test]# cat a.txt a g r e i x k like a f g liker [root@centos79 test]# cat -A a.txt a g r e$ $ $ 阅读全文
posted @ 2021-07-04 20:45 小鲨鱼2018 阅读(913) 评论(0) 推荐(1)
摘要: linux系统中如何删除空行。 1、测试数据 a.txt [root@centos79 test]# ls a.txt [root@centos79 test]# cat a.txt a g r e i x k like a f g liker [root@centos79 test]# cat - 阅读全文
posted @ 2021-07-04 20:17 小鲨鱼2018 阅读(337) 评论(0) 推荐(0)
摘要: 1、 [root@centos79 test]# cat a.txt a g r e u c j alike i x k like a f g liker a f h g liker s g e g [root@centos79 test]# grep "^a" a.txt ## 查找以a开头的行 阅读全文
posted @ 2021-07-04 19:37 小鲨鱼2018 阅读(9466) 评论(0) 推荐(0)
摘要: 1、测试数据 [root@centos79 test]# ls a.txt [root@centos79 test]# cat a.txt a g e u c j alike i x k like w f g liker s g e g [root@centos79 test]# echo "b.t 阅读全文
posted @ 2021-07-04 19:18 小鲨鱼2018 阅读(956) 评论(0) 推荐(0)
摘要: 1、测试数据 [root@centos79 test]# cat a.txt a g e u c j alike i x k like w f g liker s g e g [root@centos79 test]# grep like a.txt u c j alike i x k like w 阅读全文
posted @ 2021-07-04 18:57 小鲨鱼2018 阅读(678) 评论(0) 推荐(0)
上一页 1 ··· 291 292 293 294 295 296 297 298 299 ··· 403 下一页