Spaces:
Runtime error
Runtime error
siriuszeina
commited on
Commit
•
5d2a4e3
1
Parent(s):
330a6d1
Update app.py
Browse files
app.py
CHANGED
@@ -5,6 +5,8 @@ if os.path.exists("./output/") == False:
|
|
5 |
os.mkdir("./output/")
|
6 |
|
7 |
archived = shutil.make_archive("./output.zip", 'zip', "./output/")
|
8 |
-
|
9 |
-
|
10 |
-
st.
|
|
|
|
|
|
5 |
os.mkdir("./output/")
|
6 |
|
7 |
archived = shutil.make_archive("./output.zip", 'zip', "./output/")
|
8 |
+
output_num = len(os.listdir("./output/"))
|
9 |
+
if output_num > 0:
|
10 |
+
st.download_button(label="Download "+str(output_num)+" file", data=archived, file_name='output.zip', mime='application/x-zip'):
|
11 |
+
|
12 |
+
print(os.listdir("./"))
|