File size: 582 Bytes
d386e09
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
20b9092
d386e09
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
# ..

import os
import io
import sys
import tempfile
from datetime import datetime
from pcloud import PyCloud

current_datetime = datetime.now().strftime("%Y%m%d_%H%M%S")
temp_dir = os.path.join(tempfile.gettempdir(), "")

# BackupCurrentProject.bat
# https://7-zip.opensource.jp/chm/cmdline/switches/
os.system(f""""C:\\Program Files\\7-Zip\\7z.exe" -t7z -mx7 -mmt2 -ssw -p** -mhe a out{current_datetime}.7z outputs""")

pc = PyCloud('**', '**', endpoint="nearest")
pc.uploadfile(files=[f'out{current_datetime}.7z'], path=f'/')

os.system("pause")
sys.exit(1)