标签:练习 tr 管道
[root@node4 ~]# tr [:lower:] [:upper:] > /tmp/issue.out < /etc/issue [root@node4 ~]# tr ‘a-z‘ ‘A-Z‘ > /tmp/issue.out < /etc/issue //使用tee在输出到文件的同时显示 [root@node4 ~]# tr ‘a-z‘ ‘A-Z‘ < /etc/issue | tee /tmp/issue.out CENTOS RELEASE 6.8 (FINAL) KERNEL \R ON AN \M \L \T \U
[root@node4 wu]# who -a | tr [:lower:] [:upper:] > /tmp/who.out [root@node4 ~]# who -a | tr ‘a-z‘ ‘A-Z‘ > /tmp/who.out
echo "Hello, I am $USER, the system version is here, please help me to check it, thanks! `cat /etc/centos-release` " | mail -s help root
M1: [root@node4 ~]#echo `ls /root` al3a Documents Music Templates M2: [root@node4 ~]# ls /root | tr ‘\n‘ ‘ ‘
[root@node4 ~]# seq -s ‘ ‘ 1 9 > f [root@node4 ~]# cat f1 2 3 4 5 6 7 8 9 [root@node4 ~]# echo $((`tr ‘ ‘ ‘+‘ < f`))45
tr -d "\r" < oldfile > newfile
[root@node4 ~]# echo ‘xt.,l 1 jr#!$mn2 c*/fe3 uz4‘ > f [root@node4 ~]# tr -cd ‘0-9 ‘ < f 1 2 3 4 [root@node4 ~]# tr -cd [:digit:]+‘ ‘ <f 1 2 3 4
标签:练习 tr 管道
原文地址:http://qing5jl.blog.51cto.com/10155131/1832952