more robust: self-contained Other_Isabelle.isabelle_home;
authorwenzelm
Tue, 24 Jan 2023 15:53:13 +0100
changeset 77073 7b65209fdfe8
parent 77072 e8010cb36820
child 77074 2515198c55e4
more robust: self-contained Other_Isabelle.isabelle_home;
src/Pure/Admin/other_isabelle.scala
--- a/src/Pure/Admin/other_isabelle.scala	Tue Jan 24 15:16:24 2023 +0100
+++ b/src/Pure/Admin/other_isabelle.scala	Tue Jan 24 15:53:13 2023 +0100
@@ -66,9 +66,15 @@
     if (fresh) {
       Isabelle_System.rm_tree(isabelle_home + Path.explode("lib/classes"))
     }
+
+    val dummy_stty = Path.explode("lib/dummy_stty/stty")
+    if (!(isabelle_home + dummy_stty).is_file) {
+      Isabelle_System.copy_file(Path.ISABELLE_HOME + dummy_stty,
+        Isabelle_System.make_directory(isabelle_home + dummy_stty.dir))
+    }
     try {
       bash(
-        "export PATH=\"" + File.bash_path(Path.explode("~~/lib/dummy_stty")) + ":$PATH\"\n" +
+        "export PATH=\"" + File.bash_path(isabelle_home + dummy_stty.dir) + ":$PATH\"\n" +
         "export CLASSPATH=" + Bash.string(getenv("ISABELLE_CLASSPATH")) + "\n" +
         "bin/isabelle jedit -b", echo = echo).check
     }