Private GIT

Skip to content
Snippets Groups Projects
Commit 941de391 authored by Labrys's avatar Labrys Committed by labrys
Browse files

Streamline datetime call for backup file time-stamping

parent 9a76b255
No related branches found
No related tags found
No related merge requests found
......@@ -495,7 +495,7 @@ class SickRage(object):
for filename in filesList:
srcFile = os.path.join(srcDir, filename)
dstFile = os.path.join(dstDir, filename)
bakFile = os.path.join(dstDir, '{0}.bak-{1}'.format(filename, datetime.datetime.strftime(datetime.datetime.now(), '%Y%m%d_%H%M%S')))
bakFile = os.path.join(dstDir, '{0}.bak-{1}'.format(filename, datetime.datetime.now().strftime('%Y%m%d_%H%M%S')))
if os.path.isfile(dstFile):
shutil.move(dstFile, bakFile)
shutil.move(srcFile, dstFile)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment