From 56795bbf65ab51a3e14d2e20f10ad99ca47109e1 Mon Sep 17 00:00:00 2001 From: Julian Noble Date: Fri, 13 Mar 2026 19:56:41 +1100 Subject: [PATCH] fix regexp for examining mount output --- src/bootsupport/modules/punk/winlnk-0.1.0.tm | 2 +- src/modules/punk/winlnk-999999.0a1.0.tm | 2 +- .../src/bootsupport/modules/punk/winlnk-0.1.0.tm | 2 +- .../punk.shell-0.1/src/bootsupport/modules/punk/winlnk-0.1.0.tm | 2 +- src/vfs/_vfscommon.vfs/modules/punk/winlnk-0.1.0.tm | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/bootsupport/modules/punk/winlnk-0.1.0.tm b/src/bootsupport/modules/punk/winlnk-0.1.0.tm index 9b06a855..07bc1543 100644 --- a/src/bootsupport/modules/punk/winlnk-0.1.0.tm +++ b/src/bootsupport/modules/punk/winlnk-0.1.0.tm @@ -625,7 +625,7 @@ tcl::namespace::eval punk::winlnk { foreach line [split $mountinfo "\n"] { #review - a more specific mount target might exist that includes the drive letter as part of the mount point name and is a longer prefix of the localbase_path #- we should probably look for the longest prefix match rather than just the drive letter - if {[regexp -nocase -- [string cat ^$drive_letter {:\\\s+on\s+(\S)}] $line _match mount_point]} { + if {[regexp -nocase -- [string cat ^$drive_letter {:\\\s+on\s+(\S+)}] $line _match mount_point]} { set link_target [file join $mount_point $tail $suffix_path] break } diff --git a/src/modules/punk/winlnk-999999.0a1.0.tm b/src/modules/punk/winlnk-999999.0a1.0.tm index 35f5d75b..5ba33632 100644 --- a/src/modules/punk/winlnk-999999.0a1.0.tm +++ b/src/modules/punk/winlnk-999999.0a1.0.tm @@ -625,7 +625,7 @@ tcl::namespace::eval punk::winlnk { foreach line [split $mountinfo "\n"] { #review - a more specific mount target might exist that includes the drive letter as part of the mount point name and is a longer prefix of the localbase_path #- we should probably look for the longest prefix match rather than just the drive letter - if {[regexp -nocase -- [string cat ^$drive_letter {:\\\s+on\s+(\S)}] $line _match mount_point]} { + if {[regexp -nocase -- [string cat ^$drive_letter {:\\\s+on\s+(\S+)}] $line _match mount_point]} { set link_target [file join $mount_point $tail $suffix_path] break } diff --git a/src/project_layouts/custom/_project/punk.project-0.1/src/bootsupport/modules/punk/winlnk-0.1.0.tm b/src/project_layouts/custom/_project/punk.project-0.1/src/bootsupport/modules/punk/winlnk-0.1.0.tm index 9b06a855..07bc1543 100644 --- a/src/project_layouts/custom/_project/punk.project-0.1/src/bootsupport/modules/punk/winlnk-0.1.0.tm +++ b/src/project_layouts/custom/_project/punk.project-0.1/src/bootsupport/modules/punk/winlnk-0.1.0.tm @@ -625,7 +625,7 @@ tcl::namespace::eval punk::winlnk { foreach line [split $mountinfo "\n"] { #review - a more specific mount target might exist that includes the drive letter as part of the mount point name and is a longer prefix of the localbase_path #- we should probably look for the longest prefix match rather than just the drive letter - if {[regexp -nocase -- [string cat ^$drive_letter {:\\\s+on\s+(\S)}] $line _match mount_point]} { + if {[regexp -nocase -- [string cat ^$drive_letter {:\\\s+on\s+(\S+)}] $line _match mount_point]} { set link_target [file join $mount_point $tail $suffix_path] break } diff --git a/src/project_layouts/custom/_project/punk.shell-0.1/src/bootsupport/modules/punk/winlnk-0.1.0.tm b/src/project_layouts/custom/_project/punk.shell-0.1/src/bootsupport/modules/punk/winlnk-0.1.0.tm index 9b06a855..07bc1543 100644 --- a/src/project_layouts/custom/_project/punk.shell-0.1/src/bootsupport/modules/punk/winlnk-0.1.0.tm +++ b/src/project_layouts/custom/_project/punk.shell-0.1/src/bootsupport/modules/punk/winlnk-0.1.0.tm @@ -625,7 +625,7 @@ tcl::namespace::eval punk::winlnk { foreach line [split $mountinfo "\n"] { #review - a more specific mount target might exist that includes the drive letter as part of the mount point name and is a longer prefix of the localbase_path #- we should probably look for the longest prefix match rather than just the drive letter - if {[regexp -nocase -- [string cat ^$drive_letter {:\\\s+on\s+(\S)}] $line _match mount_point]} { + if {[regexp -nocase -- [string cat ^$drive_letter {:\\\s+on\s+(\S+)}] $line _match mount_point]} { set link_target [file join $mount_point $tail $suffix_path] break } diff --git a/src/vfs/_vfscommon.vfs/modules/punk/winlnk-0.1.0.tm b/src/vfs/_vfscommon.vfs/modules/punk/winlnk-0.1.0.tm index 9b06a855..07bc1543 100644 --- a/src/vfs/_vfscommon.vfs/modules/punk/winlnk-0.1.0.tm +++ b/src/vfs/_vfscommon.vfs/modules/punk/winlnk-0.1.0.tm @@ -625,7 +625,7 @@ tcl::namespace::eval punk::winlnk { foreach line [split $mountinfo "\n"] { #review - a more specific mount target might exist that includes the drive letter as part of the mount point name and is a longer prefix of the localbase_path #- we should probably look for the longest prefix match rather than just the drive letter - if {[regexp -nocase -- [string cat ^$drive_letter {:\\\s+on\s+(\S)}] $line _match mount_point]} { + if {[regexp -nocase -- [string cat ^$drive_letter {:\\\s+on\s+(\S+)}] $line _match mount_point]} { set link_target [file join $mount_point $tail $suffix_path] break }