proper return code for runtime failure;
authorwenzelm
Sat Sep 22 14:24:53 2018 +0200 (14 months ago)
changeset 69033c5db368833b1
parent 69032 90bb4cabe1e8
child 69034 855c3c501b09
proper return code for runtime failure;
src/Pure/Thy/present.scala
src/Pure/Tools/dump.scala
src/Pure/Tools/server.scala
src/Tools/VSCode/src/server.scala
     1.1 --- a/src/Pure/Thy/present.scala	Sat Sep 22 13:22:43 2018 +0200
     1.2 +++ b/src/Pure/Thy/present.scala	Sat Sep 22 14:24:53 2018 +0200
     1.3 @@ -319,6 +319,6 @@
     1.4        build_document(document_dir = document_dir, document_name = document_name,
     1.5          document_format = document_format, tags = tags)
     1.6      }
     1.7 -    catch { case ERROR(msg) => Output.writeln(msg); sys.exit(1) }
     1.8 +    catch { case ERROR(msg) => Output.writeln(msg); sys.exit(2) }
     1.9    })
    1.10  }
     2.1 --- a/src/Pure/Tools/dump.scala	Sat Sep 22 13:22:43 2018 +0200
     2.2 +++ b/src/Pure/Tools/dump.scala	Sat Sep 22 14:24:53 2018 +0200
     2.3 @@ -270,6 +270,6 @@
     2.4                sessions = sessions))
     2.5          }
     2.6  
     2.7 -      if (!ok) sys.exit(1)
     2.8 +      if (!ok) sys.exit(2)
     2.9      })
    2.10  }
     3.1 --- a/src/Pure/Tools/server.scala	Sat Sep 22 13:22:43 2018 +0200
     3.2 +++ b/src/Pure/Tools/server.scala	Sat Sep 22 14:24:53 2018 +0200
     3.3 @@ -485,7 +485,7 @@
     3.4        }
     3.5        else if (operation_exit) {
     3.6          val ok = Server.exit(name)
     3.7 -        sys.exit(if (ok) 0 else 1)
     3.8 +        sys.exit(if (ok) 0 else 2)
     3.9        }
    3.10        else {
    3.11          val log = Logger.make(log_file)
     4.1 --- a/src/Tools/VSCode/src/server.scala	Sat Sep 22 13:22:43 2018 +0200
     4.2 +++ b/src/Tools/VSCode/src/server.scala	Sat Sep 22 14:24:53 2018 +0200
     4.3 @@ -361,7 +361,7 @@
     4.4  
     4.5    def exit() {
     4.6      log("\n")
     4.7 -    sys.exit(if (session_.value.isDefined) 1 else 0)
     4.8 +    sys.exit(if (session_.value.isDefined) 2 else 0)
     4.9    }
    4.10  
    4.11