Просмотр исходного кода

fix timestamp check/improve logging

[SVN r27612]
Aleksey Gurtovoy 21 лет назад
Родитель
Сommit
1978769767
1 измененных файлов с 8 добавлено и 2 удалено
  1. 8 2
      tools/regression/xsl_reports/boost_wide_report.py

+ 8 - 2
tools/regression/xsl_reports/boost_wide_report.py

@@ -156,9 +156,15 @@ def sync_dirs( file_mask, source_dir, destination_dir, timestamp, do_sync ):
     files = glob.glob( os.path.join( source_dir, file_mask ) )
     for src in files:
         dst = os.path.join( destination_dir, os.path.basename( src ) )
-        utils.log( '    "%s" <-> "%s"' % ( src, dst ) )
-        if not os.path.exists( dst ) or timestamp( src ) > timestamp( dst ):
+        if not os.path.exists( dst ):
+            utils.log( '    "%s" <-> "%s" [doesn\'t exist]' % ( src, dst ) )
             do_sync( src )
+        else:
+            src_timestamp = timestamp( src )
+            dst_timestamp = timestamp( dst )
+            utils.log( '    "%s" [%s] <-> "%s" [%s]' % ( src, src_timestamp, dst, dst_timestamp ) )
+            if timestamp( src ) != timestamp( dst ):
+                do_sync( src )
 
 
 def sync_archives_task( source_dir, processed_dir, unzip_func ):

粤ICP备19079148号