First page Back Continue Last page Overview Graphics
When STDIN won't do: xargs
me@box:~$ cat test.txt
good file: 1.bin
bad file: 2.bin
bad file: 3.bin
me@box:~$ ls
test.txt
1.bin
2.bin
3.bin
me@box:~$ cat test.txt | grep data | awk {print $3}
2.bin
3.bin
me@box:~$ cat test.txt | grep data | awk '{print $3}' | xargs -I% rm %
me@box:~$ ls
test.txt