changeset 2553:069e13b4dddc beta

removed %f from datetime formatting doesn't work on py25 :/
author Marcin Kuzminski <marcin@python-works.com>
date Fri, 06 Jul 2012 00:09:10 +0200
parents e8650fbc4d4e
children e7c01410c28e
files rhodecode/model/repo.py
diffstat 1 files changed, 3 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/rhodecode/model/repo.py	Fri Jul 06 00:01:09 2012 +0200
+++ b/rhodecode/model/repo.py	Fri Jul 06 00:09:10 2012 +0200
@@ -532,6 +532,8 @@
             shutil.move(os.path.join(rm_path, '.%s' % alias),
                         os.path.join(rm_path, 'rm__.%s' % alias))
         # disable repo
-        _d = 'rm__%s__%s' % (datetime.now().strftime('%Y%m%d_%H%M%S_%f'),
+        _now = datetime.now()
+        _ms = str(_now.microsecond)
+        _d = 'rm__%s__%s' % (_now.strftime('%Y%m%d_%H%M%S_' + _ms),
                              repo.repo_name)
         shutil.move(rm_path, os.path.join(self.repos_path, _d))