I accumulate sequentially named files as the result of an automated process, and I would like to keep only the last 10 around. I tried this, which had the effect of deleting everything:
ls -r | more +11 | xargs rm
more +n causes the entire result to be piped, without regard to the
What would be the correct approach?