文章目录
cat file1
cat -n file1
cat xxx.txt awk 'NR%2==1' tac file1
more file1
less file1
head -2 file1
tail -2 file1
tail -f /log/msg
grep codesheep hello.txt
grep ^sheep hello.txt
grep [0-9] hello.txt
sed 's/s1/s2/g' hello.txt
sed '/^$/d' hello.txt
sed '/ *#/d; /^$/d' hello.txt
sed -e '1d' hello.txt
sed -n '/s1/p' hello.txt
sed -e 's/ *$//' hello.txt
sed -e 's/s1//g' hello.txt
sed -n '1,5p;5q' hello.txt
sed -n '5p;5q' hello.txt
paste file1 file2
paste -d '+' file1 file2
sort file1 file2
sort file1 file2
sort file1 file2
sort file1 file2
comm -1 file1 file2
comm -2 file1 file2
comm -3 file1 file2