lib/Tools/gofmt
changeset 80011 b082476a8036
child 80013 f1686f71dffc
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/lib/Tools/gofmt	Tue Mar 26 20:39:06 2024 +0100
@@ -0,0 +1,13 @@
+#!/usr/bin/env bash
+#
+# Author: Makarius
+#
+# DESCRIPTION: invoke gofmt within the Isabelle environment
+
+if [ -z "$ISABELLE_GOEXE" ]; then
+  echo "Missing Go installation: need to run \"isabelle go_setup\" first" >&2
+  exit 2
+else
+  export GOROOT="$ISABELLE_GOROOT"
+  exec "$ISABELLE_GOEXE/gofmt" "$@"
+fi