Advertisement
homer512

bash directory ring buffer

Sep 10th, 2014
251
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 0.15 KB | None | 0 0
  1. #!/bin/bash
  2.  
  3. # Do something with all files except the newest 10
  4.  
  5. find . -type f -printf $'%T@\t%p\n'|
  6. sort -n |
  7. cut -f2- |
  8. head -n -10 |
  9. xargs
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement