--- a/src/Pure/General/file.scala Mon Feb 04 15:45:40 2019 +0100
+++ b/src/Pure/General/file.scala Mon Feb 04 16:01:44 2019 +0100
@@ -349,9 +349,10 @@
else path.file.canExecute
}
- def executable(path: Path)
+ def set_executable(path: Path, flag: Boolean)
{
- if (Platform.is_windows) Isabelle_System.bash("chmod a+x " + bash_path(path)).check
- else path.file.setExecutable(true, false)
+ if (Platform.is_windows && flag) Isabelle_System.bash("chmod a+x " + bash_path(path)).check
+ else if (Platform.is_windows) Isabelle_System.bash("chmod a-x " + bash_path(path)).check
+ else path.file.setExecutable(flag, false)
}
}