tuned signature;
authorwenzelm
Thu Oct 13 15:17:10 2016 +0200 (2016-10-13)
changeset 64189dfb63036c4f6
parent 64188 f88bae1922c4
child 64190 c62b99e3ec07
tuned signature;
copy_dir using *this* Isabelle_System: note that File.bash_path is already expanded, but no variables are used here;
src/Pure/Admin/build_history.scala
src/Pure/Admin/other_isabelle.scala
src/Pure/System/isabelle_system.scala
     1.1 --- a/src/Pure/Admin/build_history.scala	Thu Oct 13 12:13:43 2016 +0200
     1.2 +++ b/src/Pure/Admin/build_history.scala	Thu Oct 13 15:17:10 2016 +0200
     1.3 @@ -180,7 +180,7 @@
     1.4        /* build */
     1.5  
     1.6        if (multicore_base && !first_build && isabelle_base_log.is_dir)
     1.7 -        other_isabelle.copy_dir(isabelle_base_log, isabelle_output_log)
     1.8 +        Isabelle_System.copy_dir(isabelle_base_log, isabelle_output_log)
     1.9  
    1.10        val build_start = Date.now()
    1.11        val res =
    1.12 @@ -236,7 +236,7 @@
    1.13        /* next build */
    1.14  
    1.15        if (multicore_base && first_build && isabelle_output_log.is_dir)
    1.16 -        other_isabelle.copy_dir(isabelle_output_log, isabelle_base_log)
    1.17 +        Isabelle_System.copy_dir(isabelle_output_log, isabelle_base_log)
    1.18  
    1.19        first_build = false
    1.20  
     2.1 --- a/src/Pure/Admin/other_isabelle.scala	Thu Oct 13 12:13:43 2016 +0200
     2.2 +++ b/src/Pure/Admin/other_isabelle.scala	Thu Oct 13 15:17:10 2016 +0200
     2.3 @@ -21,9 +21,6 @@
     2.4        progress_stdout = progress.echo_if(echo, _),
     2.5        progress_stderr = progress.echo_if(echo, _))
     2.6  
     2.7 -  def copy_dir(dir1: Path, dir2: Path): Unit =
     2.8 -    bash("cp -a " + File.bash_path(dir1) + " " + File.bash_path(dir2)).check
     2.9 -
    2.10    def apply(cmdline: String, redirect: Boolean = false, echo: Boolean = false): Process_Result =
    2.11      bash("bin/isabelle " + cmdline, redirect, echo)
    2.12  
     3.1 --- a/src/Pure/System/isabelle_system.scala	Thu Oct 13 12:13:43 2016 +0200
     3.2 +++ b/src/Pure/System/isabelle_system.scala	Thu Oct 13 15:17:10 2016 +0200
     3.3 @@ -173,7 +173,7 @@
     3.4    }
     3.5  
     3.6  
     3.7 -  /* mkdirs */
     3.8 +  /* directories */
     3.9  
    3.10    def mkdirs(path: Path): Unit =
    3.11      if (!path.is_dir) {
    3.12 @@ -181,6 +181,9 @@
    3.13        if (!path.is_dir) error("Failed to create directory: " + quote(File.platform_path(path)))
    3.14      }
    3.15  
    3.16 +  def copy_dir(dir1: Path, dir2: Path): Unit =
    3.17 +    bash("cp -a " + File.bash_path(dir1) + " " + File.bash_path(dir2)).check
    3.18 +
    3.19  
    3.20    /* tmp files */
    3.21