We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 9a2f402 commit eb00066Copy full SHA for eb00066
buildscripts/s3del.py
@@ -16,11 +16,30 @@
16
17
def check_dir( bucket , prefix , todel ):
18
19
+ deleteAll = False
20
+
21
for ( key , modify , etag , size ) in bucket.listdir( prefix=prefix ):
22
if key.find( todel ) < 0:
23
continue
24
print( key )
- time.sleep( 2 )
25
26
+ if not deleteAll:
27
28
+ val = raw_input( "Delete (Y,y,n,N):" ).strip()
29
30
+ if val == "n":
31
+ print( "skipping this one" )
32
+ continue
33
+ elif val == "N":
34
+ break
35
36
+ if val == "Y":
37
+ val = "y"
38
+ deleteAll = True
39
40
+ if val != "y":
41
+ raise Exception( "invalid input :(" )
42
43
bucket.delete( key )
44
45
def clean( todel ):
0 commit comments