summaryrefslogtreecommitdiff
path: root/tool/missing-baseruby.bat
diff options
context:
space:
mode:
Diffstat (limited to 'tool/missing-baseruby.bat')
-rwxr-xr-xtool/missing-baseruby.bat19
1 files changed, 19 insertions, 0 deletions
diff --git a/tool/missing-baseruby.bat b/tool/missing-baseruby.bat
new file mode 100755
index 0000000000..87a9857e06
--- /dev/null
+++ b/tool/missing-baseruby.bat
@@ -0,0 +1,19 @@
+:"" == "
+@echo off || (
+ :warn
+ echo>&2.%~1
+ goto :eof
+ :abort
+ exit /b 1
+)||(
+:)"||(
+ s = %^#
+)
+: ; call() { local call=${1#:}; shift; $call "$@"; }
+: ; warn() { echo "$1" >&2; }
+: ; abort () { exit 1; }
+
+call :warn "executable host ruby is required. use --with-baseruby option."
+call :warn "Note that BASERUBY must be Ruby 3.0.0 or later."
+call :abort
+: || (:^; abort if RUBY_VERSION < s[%r"warn .*Ruby ([\d.]+)(?:\.0)?",1])