Posts Tagged shell

find/xargs/grep tricks

Because xargs will die if you have an unescaped quote, but using -0 screws everything up if you’re reading a list of files: sed s/\’/\\\\\’/|cut -d \: -f 1|xargs -i rm “{}” The sed pattern will put the escape character in front of any single quotes so that xargs doesn’t screw up. Using md5sum to […]


No Comments