more robust: allow log to be a symlink;
authorwenzelm
Sat, 27 Oct 2018 20:11:16 +0200
changeset 69199 e5e4de2b93d9
parent 69198 9218b7652839
child 69201 0b61266fc2e0
more robust: allow log to be a symlink;
src/Pure/Admin/isabelle_cronjob.scala
--- a/src/Pure/Admin/isabelle_cronjob.scala	Sat Oct 27 15:30:38 2018 +0200
+++ b/src/Pure/Admin/isabelle_cronjob.scala	Sat Oct 27 20:11:16 2018 +0200
@@ -55,7 +55,7 @@
 
         Isabelle_System.bash(
           """rsync -a --include="*/" --include="plain_identify*" --exclude="*" """ +
-            Bash.string(backup + "/log") + " " + File.bash_path(main_dir)).check
+            Bash.string(backup + "/log/.") + " " + File.bash_path(main_dir) + "/log/.").check
 
         if (!Isabelle_Devel.cronjob_log.is_file)
           Files.createSymbolicLink(Isabelle_Devel.cronjob_log.file.toPath, current_log.file.toPath)
@@ -65,7 +65,7 @@
     Logger_Task("exit", logger =>
       {
         Isabelle_System.bash(
-          "rsync -a " + File.bash_path(main_dir + Path.explode("log")) + " " + Bash.string(backup))
+          "rsync -a " + File.bash_path(main_dir) + "/log/." + " " + Bash.string(backup) + "/log/.")
             .check
       })