Last active
January 3, 2020 16:16
-
-
Save david2331/33701bec2e64352df100e37c431802fb to your computer and use it in GitHub Desktop.
Shell script to loop through and delete s3 bucket subfolder
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
for m in 01 02 03 04 05 06 07 08 09 10 11 12 | |
do | |
for i in 01 02 03 04 05 06 07 08 09 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 27 28 29 30 31; | |
do | |
aws s3 rm s3://[bucketname]/2017$m$i --recursive; | |
done | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment