diff --git a/packages/wireshark.vm/tools/chocolateyinstall.ps1 b/packages/wireshark.vm/tools/chocolateyinstall.ps1 index c86dd14e8..7d846d085 100644 --- a/packages/wireshark.vm/tools/chocolateyinstall.ps1 +++ b/packages/wireshark.vm/tools/chocolateyinstall.ps1 @@ -7,9 +7,15 @@ try { $shortcutDir = Join-Path ${Env:TOOL_LIST_DIR} $category $shortcut = Join-Path $shortcutDir "$toolName.lnk" - $executablePath = Join-Path ${Env:ProgramFiles} "Wireshark\Wireshark.exe" -Resolve + $executablePath = Join-Path ${Env:ProgramFiles} "Wireshark\$toolName.exe" -Resolve Install-ChocolateyShortcut -shortcutFilePath $shortcut -targetPath $executablePath -RunAsAdmin VM-Assert-Path $shortcut + + # Add tshark (installed by Wireshark) to PATH and to Tools directory + $toolName = 'tshark' + $executablePath = Join-Path ${Env:ProgramFiles} "Wireshark\$toolName.exe" -Resolve + Install-BinFile -Name $toolname -Path $executablePath + VM-Install-Shortcut -toolName $toolName -category $category -executablePath $executablePath -consoleApp $true -arguments "--help" } catch { VM-Write-Log-Exception $_ } diff --git a/packages/wireshark.vm/tools/chocolateyuninstall.ps1 b/packages/wireshark.vm/tools/chocolateyuninstall.ps1 index 30cf82da4..eab16eb9c 100644 --- a/packages/wireshark.vm/tools/chocolateyuninstall.ps1 +++ b/packages/wireshark.vm/tools/chocolateyuninstall.ps1 @@ -1,7 +1,9 @@ $ErrorActionPreference = 'Continue' Import-Module vm.common -Force -DisableNameChecking -$toolName = 'Wireshark' +$toolNames = @('Wireshark', 'tshark') $category = 'Networking' -VM-Remove-Tool-Shortcut $toolName $category +ForEach ($toolName in $toolNames) { + VM-Remove-Tool-Shortcut $toolName $category +} diff --git a/packages/wireshark.vm/wireshark.vm.nuspec b/packages/wireshark.vm/wireshark.vm.nuspec index cfef1130c..12eac6920 100644 --- a/packages/wireshark.vm/wireshark.vm.nuspec +++ b/packages/wireshark.vm/wireshark.vm.nuspec @@ -2,7 +2,7 @@ wireshark.vm - 4.4.2 + 4.4.2.20250108 Wireshark lets you capture and interactively browse the traffic running on a computer network. Gerald Combs, Wireshark team