命令如下:
-
[root@aws ~]# mkdir jiaguwen
-
[root@aws ~]# touch jiaguwen.txt jiaguwen2.txt jiaguwen3.txt
-
[root@aws ~]# cd jiaguwen
-
[root@aws jiaguwen]# ls
-
jiaguwen2.txt jiaguwen3.txt jiaguwen.txt
-
[root@aws jiaguwen]# ls*.txt| xargs -n1 -i{} mv{} {}_bak
-
[root@aws jiaguwen]# ls
-
jiaguwen2.txt_bak jiaguwen3.txt_bak jiaguwen.txt_bak
当前题目:Linux小技巧,一条命令实现查找文件和改名
URL链接:
http://kswsj.cn/article/pdsics.html