diff vext @ 1719:1f4fb4a0f62a vext

Merge from branch output-type-uri
author Chris Cannam
date Tue, 27 Jun 2017 11:30:50 +0100
parents 434be2f0509e
children bf8a5ce8fb62
line wrap: on
line diff
--- a/vext	Tue Jun 20 11:44:32 2017 +0100
+++ b/vext	Tue Jun 27 11:30:50 2017 +0100
@@ -16,13 +16,13 @@
 # preference is based on startup speed.
 
 if [ -z "$sml" ]; then
+    if sml -h 2>&1 | grep -q 'Standard ML of New Jersey'; then
+	sml="smlnj"
     # I think there may be a race condition in the poly interpreter's
     # tests for open or closed I/O streams - without the "echo" here,
     # or with stderr redirection, this pipeline will sometimes hang
-    if echo | poly -v 2>/dev/null | grep -q 'Poly/ML'; then
+    elif echo | poly -v 2>/dev/null | grep -q 'Poly/ML'; then
 	sml="poly"
-    elif sml -h 2>&1 | grep -q 'Standard ML of New Jersey'; then
-	sml="smlnj"
     elif mlton 2>&1 | grep -q 'MLton'; then
 	sml="mlton"
     else cat 1>&2 <<EOF
@@ -35,17 +35,16 @@
   compiler or interpreter to run.
 
   Please ensure you have one of the following SML implementations
-  installed and present in your PATH, and try again. These are listed
-  approximately in order of preference for this task.
+  installed and present in your PATH, and try again.
 
-    1. Poly/ML
+    1. Standard ML of New Jersey
+       - often found in a distribution package called: smlnj
+       - executable name: sml
+
+    2. Poly/ML
        - often found in a distribution package called: polyml
        - executable name: poly
 
-    2. Standard ML of New Jersey
-       - often found in a distribution package called: smlnj
-       - executable name: sml
-
     3. MLton
        - often found in a distribution package called: mlton
        - executable name: mlton