假设有文件file1.txt:
aa eeeee
bb eeeee
cc eeeee
dd eeeee
先修改为:
aa eeeee 1
bb eeeee 2
cc eeeee3
dd eeeee 4
则只需要写上命令:
cat file1.txt | awk ‘{print $1,$2 " " NR}‘
标签:添加 class cat log splay inux body div controls
假设有文件file1.txt:
aa eeeee
bb eeeee
cc eeeee
dd eeeee
先修改为:
aa eeeee 1
bb eeeee 2
cc eeeee3
dd eeeee 4
则只需要写上命令:
cat file1.txt | awk ‘{print $1,$2 " " NR}‘
标签:添加 class cat log splay inux body div controls
原文地址:https://www.cnblogs.com/chenwenyan/p/8410657.html