Shell,使用sed或awk过滤字符 2016年02月03日 标签:Linux, Shell Tips eg. 过滤clean之后的字符 sed 's/\(.*clean\).*/\1/' file.txt awk -F 'clean' '{print $1""FS}' file.txt