From 5f07c49e958da4a9a226dc1bb0f85bceee2d0524 Mon Sep 17 00:00:00 2001 From: Ana Maria Martinez Gomez Date: Wed, 17 Jul 2024 15:27:58 +0200 Subject: [PATCH] [sysinternals.vm] Ensure strings is high in PATH I expect the strings from sysinternals to be the first one in the PATH (and not others like the ones in DidierStevensSuite). Use `Install-BinFile` to creates a shim for `strings.exe` in `$env:ChocolateyInstall\bin` that we ensure is on the top of the PATH after installing Python. --- packages/sysinternals.vm/sysinternals.vm.nuspec | 2 +- packages/sysinternals.vm/tools/chocolateyinstall.ps1 | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/packages/sysinternals.vm/sysinternals.vm.nuspec b/packages/sysinternals.vm/sysinternals.vm.nuspec index f04464219..f50d69e15 100644 --- a/packages/sysinternals.vm/sysinternals.vm.nuspec +++ b/packages/sysinternals.vm/sysinternals.vm.nuspec @@ -2,7 +2,7 @@ sysinternals.vm - 0.0.0.20240306 + 0.0.0.20240717 Mark Russinovich, Bryce Cogswell Sysinternals suite. diff --git a/packages/sysinternals.vm/tools/chocolateyinstall.ps1 b/packages/sysinternals.vm/tools/chocolateyinstall.ps1 index b7edc60cd..9cb4312c1 100644 --- a/packages/sysinternals.vm/tools/chocolateyinstall.ps1 +++ b/packages/sysinternals.vm/tools/chocolateyinstall.ps1 @@ -30,6 +30,11 @@ try { try { # Add sysinternals tools to path Install-ChocolateyPath $toolDir + + # Ensure strings is high in PATH + $executablePath = Join-Path $toolDir "strings.exe" -Resolve + Install-BinFile -Name strings -Path $executablePath + # Add shortcut to sysinternals folder $shortcutDir = Join-Path ${Env:TOOL_LIST_DIR} $category $shortcut = Join-Path $shortcutDir 'sysinternals.lnk'