forked from endorphant/ttbp
chmod 700 to backup tempdir
parent
95291397f4
commit
1789fb1ed4
|
@ -500,6 +500,7 @@ def process_backup(filename):
|
||||||
if not os.path.exists(backup_path):
|
if not os.path.exists(backup_path):
|
||||||
subprocess.call(["mkdir", backup_path])
|
subprocess.call(["mkdir", backup_path])
|
||||||
|
|
||||||
|
subprocess.call(["chmod", "700", backup_path])
|
||||||
subprocess.call(["tar", "-C", backup_path, "-xf", filename])
|
subprocess.call(["tar", "-C", backup_path, "-xf", filename])
|
||||||
backup_entries = os.path.join(backup_path, "entries")
|
backup_entries = os.path.join(backup_path, "entries")
|
||||||
|
|
||||||
|
|
|
@ -817,7 +817,7 @@ please enter""")
|
||||||
if not os.path.exists(config.BACKUPS):
|
if not os.path.exists(config.BACKUPS):
|
||||||
subprocess.call(["mkdir", config.BACKUPS])
|
subprocess.call(["mkdir", config.BACKUPS])
|
||||||
subprocess.call(["cp", backupfile, config.BACKUPS])
|
subprocess.call(["cp", backupfile, config.BACKUPS])
|
||||||
print("\nbackup saved!")
|
print("\nbackup saved! i also put a copy at {backup_dir} for you.".format(backup_dir = config.BACKUPS))
|
||||||
else:
|
else:
|
||||||
print("""
|
print("""
|
||||||
sorry, something went wrong! please try to address the error and try again.
|
sorry, something went wrong! please try to address the error and try again.
|
||||||
|
|
Loading…
Reference in New Issue