From 7d515ffca87eaed429811a8e4cad810903ebe67e Mon Sep 17 00:00:00 2001 From: Julian Noble Date: Thu, 3 Oct 2024 05:36:16 +1000 Subject: [PATCH] scriptwrapper update punk.tcl --- src/scriptapps/punk.tcl | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/src/scriptapps/punk.tcl b/src/scriptapps/punk.tcl index 757ae1a8..a54ed2cd 100644 --- a/src/scriptapps/punk.tcl +++ b/src/scriptapps/punk.tcl @@ -1,15 +1,16 @@ -#puts stdout "launching punk87" - +#puts stdout "launching punk" set dirname [file dirname [file normalize [info script]]] if {[file tail $dirname] eq "bin"} { - if {[file exists [file join $dirname ../src/punk86.vfs/main.tcl]]} { - #tclsh [file join $dirname ../src/punk86.vfs/main.tcl] {*}$::argv - source [file join $dirname ../src/punk86.vfs/main.tcl] + lassign [split [info tclversion] .] tclmajorv tclminorv + set launchpath "../src/vfs/punk${tclmajorv}win.vfs/main.tcl" + if {[file exists [file join $dirname $launchpath]]} { + #tclsh [file join $dirname $launchpath] {*}$::argv + source [file join $dirname $launchpath] } else { - puts stderr "Unable to locate punk87 entry-point main.tcl" + puts stderr "Unable to locate punk${tclmajorv} entry-point main.tcl tried:$launchpath" } } else { - puts stderr "punk87 launch script must be run from the punk bin folder" + puts stderr "punk launch script must be located in the punk bin folder" } #puts stdout "-done-"