Delete all but the most recent N files from s3://bucket Here is a introductory: https://www.padory.com/p/53f629ffb25be85c0b000004