管道及I/O重定向
输出重定向
date > a.txtdate 1>> a.txtls /home/ /aa >> a.txt 2>b.txtls /home/ /aa &> a.txt
ls /home/ /aa > a.txt 2>&1ls /home/ /aa &> /dev/null输入重定向
grep 'root' < /etc/passwdmysql -uroot -p123 < aa.sql总和应用
Last updated
date > a.txtdate 1>> a.txtls /home/ /aa >> a.txt 2>b.txtls /home/ /aa &> a.txt
ls /home/ /aa > a.txt 2>&1ls /home/ /aa &> /dev/nullgrep 'root' < /etc/passwdmysql -uroot -p123 < aa.sqlLast updated
cat > a.txt <<EOF
> 11
> 22
> EOF