gerardog / gsudo

Sudo for Windows
https://gerardog.github.io/gsudo
MIT License
5.21k stars 138 forks source link

gsudo not found after install #34

Closed black-snow closed 4 years ago

black-snow commented 4 years ago

I ran choco install gsudo and refreshenv from an elevated powershell and even reopened the powershell. Installation went fine but when I type gsudo in an unelevated prompt:

gsudo : Die Benennung "gsudo" wurde nicht als Name eines Cmdlet, einer Funktion, einer Skriptdatei oder eines ausführbaren Programms erkannt. Überprüfen Sie die Schreibweise des Namens, oder ob der Pfad korrekt ist (sofern enthalten), und wiederholen Sie den Vorgang. In Zeile:1 Zeichen:1

  • gsudo
  • 
    + CategoryInfo          : ObjectNotFound: (gsudo:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException

(which translate to not found).

Running gsudo from an elevated prompt:

Error: Already running as the specified user/permission-level (and no command specified). Exiting...

Of course I cannot install gsudo from an unprivileged ps.

gerardog commented 4 years ago

Error: Already running as the specified user/permission-level (and no command specified). Exiting...

This is expected, if you gsudo with no command from an already elevated console. It seems gsudo is correctly in your PATH environment variable when you are elevated. I don't know why it's not when you are not-elevated. This folder should be part of your PATH C:\ProgramData\chocolatey\lib\gsudo\bin\

Does the problem persists after a reboot?

If so, you may want to provide the gsudo relevant parts in order to understand what failed during the install from C:\ProgramData\chocolatey\logs\chocolatey.log.

I think it is probable that this will get fixed if you open an elevated console and reinstall gsudo, with choco install gsudo -f and accepting (Y) all parts, or choco uninstall gsudo then choco install gsudo.

black-snow commented 4 years ago

Does the problem persists after a reboot?

yes

The log is huge:

2020-05-26 10:01:23,487 12608 [DEBUG] - XmlConfiguration is now operational
2020-05-26 10:01:23,514 12608 [INFO ] - ============================================================
2020-05-26 10:01:23,615 12608 [INFO ] - Chocolatey v0.10.15
2020-05-26 10:01:23,620 12608 [DEBUG] - Chocolatey is running on Windows v 10.0.18363.0
2020-05-26 10:01:23,621 12608 [DEBUG] - Attempting to delete file "C:/ProgramData/chocolatey/choco.exe.old".
2020-05-26 10:01:23,621 12608 [DEBUG] - Attempting to delete file "C:\ProgramData\chocolatey\choco.exe.old".
2020-05-26 10:01:23,626 12608 [DEBUG] - Command line: "C:\ProgramData\chocolatey\choco.exe" install gsudo
2020-05-26 10:01:23,627 12608 [DEBUG] - Received arguments: install gsudo
2020-05-26 10:01:23,654 12608 [DEBUG] - RemovePendingPackagesTask is now ready and waiting for PreRunMessage.
2020-05-26 10:01:23,658 12608 [DEBUG] - Sending message 'PreRunMessage' out if there are subscribers...
2020-05-26 10:01:23,662 12608 [DEBUG] - [Pending] Removing all pending packages that should not be considered installed...
2020-05-26 10:01:23,702 12608 [DEBUG] - Performing validation checks.
2020-05-26 10:01:23,706 12608 [DEBUG] - Global Configuration Validation Checks:
2020-05-26 10:01:23,706 12608 [DEBUG] -  - Package Exit Code / Exit On Reboot = Checked
2020-05-26 10:01:23,707 12608 [DEBUG] - System State Validation Checks:
2020-05-26 10:01:23,708 12608 [DEBUG] -  Reboot Requirement Checks:
2020-05-26 10:01:23,709 12608 [DEBUG] -  - Pending Computer Rename = Checked
2020-05-26 10:01:23,710 12608 [DEBUG] -  - Pending Component Based Servicing = Checked
2020-05-26 10:01:23,711 12608 [DEBUG] -  - Pending Windows Auto Update = Checked
2020-05-26 10:01:23,712 12608 [DEBUG] -  - Pending File Rename Operations = Checked
2020-05-26 10:01:23,712 12608 [DEBUG] -  - Pending Windows Package Installer = Checked
2020-05-26 10:01:23,713 12608 [DEBUG] -  - Pending Windows Package Installer SysWow64 = Checked
2020-05-26 10:01:23,715 12608 [INFO ] - 2 validations performed. 2 success(es), 0 warning(s), and 0 error(s).
2020-05-26 10:01:23,717 12608 [DEBUG] - The source 'https://chocolatey.org/api/v2/' evaluated to a 'normal' source type
2020-05-26 10:01:23,717 12608 [DEBUG] - 
NOTE: Hiding sensitive configuration data! Please double and triple
 check to be sure no sensitive data is shown, especially if copying
 output to a gist for review.
2020-05-26 10:01:23,726 12608 [DEBUG] - Configuration: CommandName='install'|
CacheLocation='C:\Users\admin\AppData\Local\Temp\chocolatey'|
ContainsLegacyPackageInstalls='True'|
CommandExecutionTimeoutSeconds='2700'|WebRequestTimeoutSeconds='30'|
Sources='https://chocolatey.org/api/v2/'|SourceType='normal'|
Debug='False'|Verbose='False'|Trace='False'|Force='False'|Noop='False'|
HelpRequested='False'|UnsuccessfulParsing='False'|RegularOutput='True'|
QuietOutput='False'|PromptForConfirmation='True'|AcceptLicense='False'|
AllowUnofficialBuild='False'|Input='gsudo'|AllVersions='False'|
SkipPackageInstallProvider='False'|PackageNames='gsudo'|
Prerelease='False'|ForceX86='False'|OverrideArguments='False'|
NotSilent='False'|ApplyPackageParametersToDependencies='False'|
ApplyInstallArgumentsToDependencies='False'|IgnoreDependencies='False'|
AllowMultipleVersions='False'|AllowDowngrade='False'|
ForceDependencies='False'|Information.PlatformType='Windows'|
Information.PlatformVersion='10.0.18363.0'|
Information.PlatformName='Windows 10'|
Information.ChocolateyVersion='0.10.15.0'|
Information.ChocolateyProductVersion='0.10.15'|
Information.FullName='choco, Version=0.10.15.0, Culture=neutral, PublicKeyToken=79d02ea9cad655eb'|

Information.Is64BitOperatingSystem='True'|
Information.Is64BitProcess='True'|Information.IsInteractive='True'|
Information.UserName='admin'|Information.UserDomainName='PC-256'|
Information.IsUserAdministrator='True'|
Information.IsUserSystemAccount='False'|
Information.IsUserRemoteDesktop='False'|
Information.IsUserRemote='True'|
Information.IsProcessElevated='True'|
Information.IsLicensedVersion='False'|Information.LicenseType='Foss'|
Information.CurrentDirectory='C:\windows\system32'|
Features.AutoUninstaller='True'|Features.ChecksumFiles='True'|
Features.AllowEmptyChecksums='False'|
Features.AllowEmptyChecksumsSecure='True'|
Features.FailOnAutoUninstaller='False'|
Features.FailOnStandardError='False'|Features.UsePowerShellHost='True'|
Features.LogEnvironmentValues='False'|Features.LogWithoutColor='False'|
Features.VirusCheck='False'|
Features.FailOnInvalidOrMissingLicense='False'|
Features.IgnoreInvalidOptionsSwitches='True'|
Features.UsePackageExitCodes='True'|
Features.UseEnhancedExitCodes='False'|
Features.UseFipsCompliantChecksums='False'|
Features.ShowNonElevatedWarnings='True'|
Features.ShowDownloadProgress='True'|
Features.StopOnFirstPackageFailure='False'|
Features.UseRememberedArgumentsForUpgrades='False'|
Features.IgnoreUnfoundPackagesOnUpgradeOutdated='False'|
Features.SkipPackageUpgradesWhenNotInstalled='False'|
Features.RemovePackageInformationOnUninstall='False'|
Features.ExitOnRebootDetected='False'|
Features.LogValidationResultsOnWarnings='True'|
Features.UsePackageRepositoryOptimizations='True'|
Features.ScriptsCheckLastExitCode='False'|
ListCommand.LocalOnly='False'|
ListCommand.IdOnly='False'|ListCommand.IncludeRegistryPrograms='False'|
ListCommand.PageSize='25'|ListCommand.Exact='False'|
ListCommand.ByIdOnly='False'|ListCommand.ByTagOnly='False'|
ListCommand.IdStartsWith='False'|ListCommand.OrderByPopularity='False'|
ListCommand.ApprovedOnly='False'|
ListCommand.DownloadCacheAvailable='False'|
ListCommand.NotBroken='False'|
ListCommand.IncludeVersionOverrides='False'|
UpgradeCommand.FailOnUnfound='False'|
UpgradeCommand.FailOnNotInstalled='False'|
UpgradeCommand.NotifyOnlyAvailableUpgrades='False'|
UpgradeCommand.ExcludePrerelease='False'|
NewCommand.AutomaticPackage='False'|
NewCommand.UseOriginalTemplate='False'|SourceCommand.Command='unknown'|
SourceCommand.Priority='0'|SourceCommand.BypassProxy='False'|
SourceCommand.AllowSelfService='False'|
SourceCommand.VisibleToAdminsOnly='False'|
FeatureCommand.Command='unknown'|ConfigCommand.Command='unknown'|
ApiKeyCommand.Remove='False'|PinCommand.Command='unknown'|
OutdatedCommand.IgnorePinned='False'|Proxy.BypassOnLocal='True'|
2020-05-26 10:01:23,727 12608 [DEBUG] - _ Chocolatey:ChocolateyInstallCommand - Normal Run Mode _
2020-05-26 10:01:23,729 12608 [INFO ] - Installing the following packages:
2020-05-26 10:01:23,730 12608 [INFO ] - gsudo
2020-05-26 10:01:23,731 12608 [INFO ] - By installing you accept licenses for the packages.
2020-05-26 10:01:23,779 12608 [DEBUG] - Using 'https://chocolatey.org/api/v2/'.
2020-05-26 10:01:24,162 12608 [DEBUG] - - Supports prereleases? 'True'.
2020-05-26 10:01:24,164 12608 [DEBUG] - - Is ServiceBased? 'True'.
2020-05-26 10:01:24,795 12608 [DEBUG] - Package 'gsudo' found on source 'https://chocolatey.org/api/v2/'
2020-05-26 10:01:25,740 12608 [INFO ] - [NuGet] Installing 'gsudo 0.7.0'.
2020-05-26 10:01:25,744 12608 [DEBUG] - [NuGet] Added file 'gsudo.exe' to folder 'gsudo\bin'.
2020-05-26 10:01:25,744 12608 [DEBUG] - [NuGet] Added file 'gsudo.exe.ignore' to folder 'gsudo\bin'.
2020-05-26 10:01:25,745 12608 [DEBUG] - [NuGet] Added file 'sudo.exe.ignore' to folder 'gsudo\bin'.
2020-05-26 10:01:25,746 12608 [DEBUG] - [NuGet] Added file 'chocolateybeforemodify.ps1' to folder 'gsudo\tools'.
2020-05-26 10:01:25,747 12608 [DEBUG] - [NuGet] Added file 'chocolateyinstall.ps1' to folder 'gsudo\tools'.
2020-05-26 10:01:25,748 12608 [DEBUG] - [NuGet] Added file 'chocolateyuninstall.ps1' to folder 'gsudo\tools'.
2020-05-26 10:01:25,749 12608 [DEBUG] - [NuGet] Added file 'LICENSE.txt' to folder 'gsudo\tools'.
2020-05-26 10:01:25,750 12608 [DEBUG] - [NuGet] Added file 'Uninstall-ChocolateyPath.psm1' to folder 'gsudo\tools'.
2020-05-26 10:01:25,750 12608 [DEBUG] - [NuGet] Added file 'VERIFICATION.txt' to folder 'gsudo\tools'.
2020-05-26 10:01:25,752 12608 [DEBUG] - [NuGet] Added file 'gsudo.nupkg' to folder 'gsudo'.
2020-05-26 10:01:25,993 12608 [DEBUG] - [NuGet] Added file 'gsudo.nuspec' to folder 'gsudo'.
2020-05-26 10:01:25,994 12608 [INFO ] - [NuGet] Successfully installed 'gsudo 0.7.0'.
2020-05-26 10:01:25,995 12608 [INFO ] - 
gsudo v0.7.0 [Approved]
2020-05-26 10:01:26,002 12608 [INFO ] - gsudo package files install completed. Performing other installation steps.
2020-05-26 10:01:26,040 12608 [DEBUG] - Setting installer args for gsudo
2020-05-26 10:01:26,040 12608 [DEBUG] - Setting package parameters for gsudo
2020-05-26 10:01:26,041 12608 [DEBUG] - Contents of 'C:\ProgramData\chocolatey\lib\gsudo\tools\chocolateyinstall.ps1':
2020-05-26 10:01:26,045 12608 [DEBUG] - function Test-IsSymLink([string]$path) {
  $file = Get-Item $path -Force -ea SilentlyContinue
  return [bool]($file.Attributes -band [IO.FileAttributes]::ReparsePoint)
}

if (Get-Process gsudo -ErrorAction SilentlyContinue) {
    gsudo.exe -k
    Start-Sleep -Milliseconds 500
    if (Get-Process gsudo -ErrorAction SilentlyContinue) {
        $ErrorActionPreference = "Stop"
        Write-Output '##### Please close gsudo before installing.             #####'
        Write-Output '##### Or run in new window with "-n" to let gsudo exit: #####'
        Write-Output '        gsudo -n cmd /k choco upgrade gsudo'

        throw "Unable to install/uninstall if gsudo is running"
    }
}

$bin = "$env:ChocolateyInstall\lib\gsudo\bin\"

if (Test-Path "$bin\sudo.exe")
{
  Remove-Item "$bin\sudo.exe"
}

Install-ChocolateyPath -PathToInstall $bin -PathType 'User'

cmd /c mklink "$bin\sudo.exe" "$bin\gsudo.exe"

if (Test-Path "$env:ChocolateyInstall\bin\gsudo.exe")  # Previous installers created symlinks on chocolatey\bin, we no longer need them.
{ 
  Remove-Item "$env:ChocolateyInstall\bin\gsudo.exe"
  if (Test-IsSymLink "$env:ChocolateyInstall\bin\sudo.exe")
  {
    Remove-Item "$env:ChocolateyInstall\bin\sudo.exe"
  }
}

Write-Output "Done."

2020-05-26 10:01:26,046 12608 [INFO ] - The package gsudo wants to run 'chocolateyinstall.ps1'.
2020-05-26 10:01:26,047 12608 [INFO ] - Note: If you don't run this script, the installation will fail.
2020-05-26 10:01:26,048 12608 [INFO ] - Note: To confirm automatically next time, use '-y' or consider:
2020-05-26 10:01:26,049 12608 [INFO ] - choco feature enable -n allowGlobalConfirmation
2020-05-26 10:01:26,059 12608 [INFO ] - Do you want to run the script?
2020-05-26 10:01:26,060 12608 [INFO ] -  1) yes
2020-05-26 10:01:26,060 12608 [INFO ] -  2) all - yes to all
2020-05-26 10:01:26,061 12608 [INFO ] -  3) no
2020-05-26 10:01:26,062 12608 [INFO ] -  4) print
2020-05-26 10:01:27,070 12608 [INFO ] - Choice selected: 'yes'
2020-05-26 10:01:27,083 12608 [DEBUG] - Calling built-in PowerShell host with ['[System.Threading.Thread]::CurrentThread.CurrentCulture = '';[System.Threading.Thread]::CurrentThread.CurrentUICulture = ''; & import-module -name 'C:\ProgramData\chocolatey\helpers\chocolateyInstaller.psm1'; & 'C:\ProgramData\chocolatey\helpers\chocolateyScriptRunner.ps1' -packageScript 'C:\ProgramData\chocolatey\lib\gsudo\tools\chocolateyinstall.ps1' -installArguments '' -packageParameters ''']
2020-05-26 10:01:27,085 12608 [DEBUG] - Redirecting System.Management.Automation.resources, Version=3.0.0.0, Culture=de-DE, PublicKeyToken=31bf3856ad364e35, requested by ''
2020-05-26 10:01:27,224 12608 [DEBUG] - Host version is 5.1.18362.1, PowerShell Version is '5.1.18362.752' and CLR Version is '4.0.30319.42000'.
2020-05-26 10:01:27,617 12608 [INFO ] - VERBOSE: Exporting function 'Format-FileSize'.
2020-05-26 10:01:27,618 12608 [INFO ] - VERBOSE: Exporting function 'Get-ChecksumValid'.
2020-05-26 10:01:27,618 12608 [INFO ] - VERBOSE: Exporting function 'Get-ChocolateyUnzip'.
2020-05-26 10:01:27,619 12608 [INFO ] - VERBOSE: Exporting function 'Get-ChocolateyWebFile'.
2020-05-26 10:01:27,619 12608 [INFO ] - VERBOSE: Exporting function 'Get-EnvironmentVariable'.
2020-05-26 10:01:27,619 12608 [INFO ] - VERBOSE: Exporting function 'Get-EnvironmentVariableNames'.
2020-05-26 10:01:27,620 12608 [INFO ] - VERBOSE: Exporting function 'Get-FtpFile'.
2020-05-26 10:01:27,620 12608 [INFO ] - VERBOSE: Exporting function 'Get-OSArchitectureWidth'.
2020-05-26 10:01:27,620 12608 [INFO ] - VERBOSE: Exporting function 'Get-PackageParameters'.
2020-05-26 10:01:27,621 12608 [INFO ] - VERBOSE: Exporting function 'Get-PackageParametersBuiltIn'.
2020-05-26 10:01:27,621 12608 [INFO ] - VERBOSE: Exporting function 'Get-ToolsLocation'.
2020-05-26 10:01:27,621 12608 [INFO ] - VERBOSE: Exporting function 'Get-UACEnabled'.
2020-05-26 10:01:27,622 12608 [INFO ] - VERBOSE: Exporting function 'Get-UninstallRegistryKey'.
2020-05-26 10:01:27,622 12608 [INFO ] - VERBOSE: Exporting function 'Get-VirusCheckValid'.
2020-05-26 10:01:27,623 12608 [INFO ] - VERBOSE: Exporting function 'Get-WebFile'.
2020-05-26 10:01:27,623 12608 [INFO ] - VERBOSE: Exporting function 'Get-WebFileName'.
2020-05-26 10:01:27,623 12608 [INFO ] - VERBOSE: Exporting function 'Get-WebHeaders'.
2020-05-26 10:01:27,624 12608 [INFO ] - VERBOSE: Exporting function 'Install-BinFile'.
2020-05-26 10:01:27,624 12608 [INFO ] - VERBOSE: Exporting function 'Install-ChocolateyDesktopLink'.
2020-05-26 10:01:27,624 12608 [INFO ] - VERBOSE: Exporting function 'Install-ChocolateyEnvironmentVariable'.
2020-05-26 10:01:27,625 12608 [INFO ] - VERBOSE: Exporting function 'Install-ChocolateyExplorerMenuItem'.
2020-05-26 10:01:27,625 12608 [INFO ] - VERBOSE: Exporting function 'Install-ChocolateyFileAssociation'.
2020-05-26 10:01:27,625 12608 [INFO ] - VERBOSE: Exporting function 'Install-ChocolateyInstallPackage'.
2020-05-26 10:01:27,626 12608 [INFO ] - VERBOSE: Exporting function 'Install-ChocolateyPackage'.
2020-05-26 10:01:27,626 12608 [INFO ] - VERBOSE: Exporting function 'Install-ChocolateyPath'.
2020-05-26 10:01:27,626 12608 [INFO ] - VERBOSE: Exporting function 'Install-ChocolateyPinnedTaskBarItem'.
2020-05-26 10:01:27,627 12608 [INFO ] - VERBOSE: Exporting function 'Install-ChocolateyPowershellCommand'.
2020-05-26 10:01:27,627 12608 [INFO ] - VERBOSE: Exporting function 'Install-ChocolateyShortcut'.
2020-05-26 10:01:27,627 12608 [INFO ] - VERBOSE: Exporting function 'Install-ChocolateyVsixPackage'.
2020-05-26 10:01:27,627 12608 [INFO ] - VERBOSE: Exporting function 'Install-ChocolateyZipPackage'.
2020-05-26 10:01:27,628 12608 [INFO ] - VERBOSE: Exporting function 'Install-Vsix'.
2020-05-26 10:01:27,628 12608 [INFO ] - VERBOSE: Exporting function 'Set-EnvironmentVariable'.
2020-05-26 10:01:27,628 12608 [INFO ] - VERBOSE: Exporting function 'Set-PowerShellExitCode'.
2020-05-26 10:01:27,629 12608 [INFO ] - VERBOSE: Exporting function 'Start-ChocolateyProcessAsAdmin'.
2020-05-26 10:01:27,629 12608 [INFO ] - VERBOSE: Exporting function 'Test-ProcessAdminRights'.
2020-05-26 10:01:27,629 12608 [INFO ] - VERBOSE: Exporting function 'Uninstall-BinFile'.
2020-05-26 10:01:27,630 12608 [INFO ] - VERBOSE: Exporting function 'Uninstall-ChocolateyEnvironmentVariable'.
2020-05-26 10:01:27,630 12608 [INFO ] - VERBOSE: Exporting function 'Uninstall-ChocolateyPackage'.
2020-05-26 10:01:27,630 12608 [INFO ] - VERBOSE: Exporting function 'Uninstall-ChocolateyZipPackage'.
2020-05-26 10:01:27,631 12608 [INFO ] - VERBOSE: Exporting function 'Update-SessionEnvironment'.
2020-05-26 10:01:27,631 12608 [INFO ] - VERBOSE: Exporting function 'Write-ChocolateyFailure'.
2020-05-26 10:01:27,631 12608 [INFO ] - VERBOSE: Exporting function 'Write-ChocolateySuccess'.
2020-05-26 10:01:27,632 12608 [INFO ] - VERBOSE: Exporting function 'Write-FileUpdateLog'.
2020-05-26 10:01:27,632 12608 [INFO ] - VERBOSE: Exporting function 'Write-FunctionCallLogMessage'.
2020-05-26 10:01:27,633 12608 [INFO ] - VERBOSE: Exporting alias 'Get-ProcessorBits'.
2020-05-26 10:01:27,633 12608 [INFO ] - VERBOSE: Exporting alias 'Get-OSBitness'.
2020-05-26 10:01:27,633 12608 [INFO ] - VERBOSE: Exporting alias 'Get-InstallRegistryKey'.
2020-05-26 10:01:27,634 12608 [INFO ] - VERBOSE: Exporting alias 'Generate-BinFile'.
2020-05-26 10:01:27,634 12608 [INFO ] - VERBOSE: Exporting alias 'Add-BinFile'.
2020-05-26 10:01:27,634 12608 [INFO ] - VERBOSE: Exporting alias 'Start-ChocolateyProcess'.
2020-05-26 10:01:27,635 12608 [INFO ] - VERBOSE: Exporting alias 'Invoke-ChocolateyProcess'.
2020-05-26 10:01:27,635 12608 [INFO ] - VERBOSE: Exporting alias 'Remove-BinFile'.
2020-05-26 10:01:27,635 12608 [INFO ] - VERBOSE: Exporting alias 'refreshenv'.
2020-05-26 10:01:27,640 12608 [DEBUG] - Loading community extensions
2020-05-26 10:01:27,646 12608 [DEBUG] - Importing 'C:\ProgramData\chocolatey\extensions\chocolatey-core\chocolatey-core.psm1'
2020-05-26 10:01:27,646 12608 [INFO ] - VERBOSE: Loading module from path 'C:\ProgramData\chocolatey\extensions\chocolatey-core\chocolatey-core.psm1'.
2020-05-26 10:01:27,705 12608 [INFO ] - VERBOSE: Exporting function 'Get-UninstallRegistryKey'.
2020-05-26 10:01:27,706 12608 [INFO ] - VERBOSE: Exporting function 'Get-AppInstallLocation'.
2020-05-26 10:01:27,707 12608 [INFO ] - VERBOSE: Exporting function 'Get-AvailableDriveLetter'.
2020-05-26 10:01:27,707 12608 [INFO ] - VERBOSE: Exporting function 'Get-EffectiveProxy'.
2020-05-26 10:01:27,708 12608 [INFO ] - VERBOSE: Exporting function 'Get-PackageCacheLocation'.
2020-05-26 10:01:27,708 12608 [INFO ] - VERBOSE: Exporting function 'Get-PackageParameters'.
2020-05-26 10:01:27,709 12608 [INFO ] - VERBOSE: Exporting function 'Get-WebContent'.
2020-05-26 10:01:27,709 12608 [INFO ] - VERBOSE: Exporting function 'Register-Application'.
2020-05-26 10:01:27,710 12608 [INFO ] - VERBOSE: Exporting function 'Remove-Process'.
2020-05-26 10:01:27,710 12608 [INFO ] - VERBOSE: Importing function 'Get-AppInstallLocation'.
2020-05-26 10:01:27,711 12608 [INFO ] - VERBOSE: Importing function 'Get-AvailableDriveLetter'.
2020-05-26 10:01:27,711 12608 [INFO ] - VERBOSE: Importing function 'Get-EffectiveProxy'.
2020-05-26 10:01:27,712 12608 [INFO ] - VERBOSE: Importing function 'Get-PackageCacheLocation'.
2020-05-26 10:01:27,712 12608 [INFO ] - VERBOSE: Importing function 'Get-PackageParameters'.
2020-05-26 10:01:27,712 12608 [INFO ] - VERBOSE: Importing function 'Get-UninstallRegistryKey'.
2020-05-26 10:01:27,713 12608 [INFO ] - VERBOSE: Importing function 'Get-WebContent'.
2020-05-26 10:01:27,713 12608 [INFO ] - VERBOSE: Importing function 'Register-Application'.
2020-05-26 10:01:27,713 12608 [INFO ] - VERBOSE: Importing function 'Remove-Process'.
2020-05-26 10:01:27,714 12608 [DEBUG] - Importing 'C:\ProgramData\chocolatey\extensions\chocolatey-dotnetfx\chocolatey-dotnetfx.psm1'
2020-05-26 10:01:27,714 12608 [INFO ] - VERBOSE: Loading module from path 'C:\ProgramData\chocolatey\extensions\chocolatey-dotnetfx\chocolatey-dotnetfx.psm1'.
2020-05-26 10:01:27,743 12608 [INFO ] - VERBOSE: Exporting function 'Install-DotNetFramework'.
2020-05-26 10:01:27,744 12608 [INFO ] - VERBOSE: Exporting function 'Install-DotNetDevPack'.
2020-05-26 10:01:27,744 12608 [INFO ] - VERBOSE: Importing function 'Install-DotNetDevPack'.
2020-05-26 10:01:27,745 12608 [INFO ] - VERBOSE: Importing function 'Install-DotNetFramework'.
2020-05-26 10:01:27,745 12608 [DEBUG] - Importing 'C:\ProgramData\chocolatey\extensions\chocolatey-windowsupdate\chocolatey-windowsupdate.psm1'
2020-05-26 10:01:27,746 12608 [INFO ] - VERBOSE: Loading module from path 'C:\ProgramData\chocolatey\extensions\chocolatey-windowsupdate\chocolatey-windowsupdate.psm1'.
2020-05-26 10:01:27,797 12608 [INFO ] - VERBOSE: Exporting function 'Install-WindowsUpdate'.
2020-05-26 10:01:27,798 12608 [INFO ] - VERBOSE: Exporting function 'Test-WindowsUpdate'.
2020-05-26 10:01:27,798 12608 [INFO ] - VERBOSE: Importing function 'Install-WindowsUpdate'.
2020-05-26 10:01:27,798 12608 [INFO ] - VERBOSE: Importing function 'Test-WindowsUpdate'.
2020-05-26 10:01:27,799 12608 [INFO ] - VERBOSE: Exporting function 'Format-FileSize'.
2020-05-26 10:01:27,799 12608 [INFO ] - VERBOSE: Exporting function 'Get-ChecksumValid'.
2020-05-26 10:01:27,800 12608 [INFO ] - VERBOSE: Exporting function 'Get-ChocolateyUnzip'.
2020-05-26 10:01:27,800 12608 [INFO ] - VERBOSE: Exporting function 'Get-ChocolateyWebFile'.
2020-05-26 10:01:27,801 12608 [INFO ] - VERBOSE: Exporting function 'Get-EnvironmentVariable'.
2020-05-26 10:01:27,801 12608 [INFO ] - VERBOSE: Exporting function 'Get-EnvironmentVariableNames'.
2020-05-26 10:01:27,801 12608 [INFO ] - VERBOSE: Exporting function 'Get-FtpFile'.
2020-05-26 10:01:27,802 12608 [INFO ] - VERBOSE: Exporting function 'Get-OSArchitectureWidth'.
2020-05-26 10:01:27,802 12608 [INFO ] - VERBOSE: Exporting function 'Get-PackageParameters'.
2020-05-26 10:01:27,803 12608 [INFO ] - VERBOSE: Exporting function 'Get-PackageParametersBuiltIn'.
2020-05-26 10:01:27,803 12608 [INFO ] - VERBOSE: Exporting function 'Get-ToolsLocation'.
2020-05-26 10:01:27,803 12608 [INFO ] - VERBOSE: Exporting function 'Get-UACEnabled'.
2020-05-26 10:01:27,804 12608 [INFO ] - VERBOSE: Exporting function 'Get-UninstallRegistryKey'.
2020-05-26 10:01:27,804 12608 [INFO ] - VERBOSE: Exporting function 'Get-VirusCheckValid'.
2020-05-26 10:01:27,804 12608 [INFO ] - VERBOSE: Exporting function 'Get-WebFile'.
2020-05-26 10:01:27,805 12608 [INFO ] - VERBOSE: Exporting function 'Get-WebFileName'.
2020-05-26 10:01:27,805 12608 [INFO ] - VERBOSE: Exporting function 'Get-WebHeaders'.
2020-05-26 10:01:27,805 12608 [INFO ] - VERBOSE: Exporting function 'Install-BinFile'.
2020-05-26 10:01:27,806 12608 [INFO ] - VERBOSE: Exporting function 'Install-ChocolateyDesktopLink'.
2020-05-26 10:01:27,806 12608 [INFO ] - VERBOSE: Exporting function 'Install-ChocolateyEnvironmentVariable'.
2020-05-26 10:01:27,806 12608 [INFO ] - VERBOSE: Exporting function 'Install-ChocolateyExplorerMenuItem'.
2020-05-26 10:01:27,807 12608 [INFO ] - VERBOSE: Exporting function 'Install-ChocolateyFileAssociation'.
2020-05-26 10:01:27,807 12608 [INFO ] - VERBOSE: Exporting function 'Install-ChocolateyInstallPackage'.
2020-05-26 10:01:27,807 12608 [INFO ] - VERBOSE: Exporting function 'Install-ChocolateyPackage'.
2020-05-26 10:01:27,808 12608 [INFO ] - VERBOSE: Exporting function 'Install-ChocolateyPath'.
2020-05-26 10:01:27,808 12608 [INFO ] - VERBOSE: Exporting function 'Install-ChocolateyPinnedTaskBarItem'.
2020-05-26 10:01:27,808 12608 [INFO ] - VERBOSE: Exporting function 'Install-ChocolateyPowershellCommand'.
2020-05-26 10:01:27,809 12608 [INFO ] - VERBOSE: Exporting function 'Install-ChocolateyShortcut'.
2020-05-26 10:01:27,809 12608 [INFO ] - VERBOSE: Exporting function 'Install-ChocolateyVsixPackage'.
2020-05-26 10:01:27,809 12608 [INFO ] - VERBOSE: Exporting function 'Install-ChocolateyZipPackage'.
2020-05-26 10:01:27,810 12608 [INFO ] - VERBOSE: Exporting function 'Install-Vsix'.
2020-05-26 10:01:27,810 12608 [INFO ] - VERBOSE: Exporting function 'Set-EnvironmentVariable'.
2020-05-26 10:01:27,810 12608 [INFO ] - VERBOSE: Exporting function 'Set-PowerShellExitCode'.
2020-05-26 10:01:27,811 12608 [INFO ] - VERBOSE: Exporting function 'Start-ChocolateyProcessAsAdmin'.
2020-05-26 10:01:27,811 12608 [INFO ] - VERBOSE: Exporting function 'Test-ProcessAdminRights'.
2020-05-26 10:01:27,811 12608 [INFO ] - VERBOSE: Exporting function 'Uninstall-BinFile'.
2020-05-26 10:01:27,812 12608 [INFO ] - VERBOSE: Exporting function 'Uninstall-ChocolateyEnvironmentVariable'.
2020-05-26 10:01:27,812 12608 [INFO ] - VERBOSE: Exporting function 'Uninstall-ChocolateyPackage'.
2020-05-26 10:01:27,812 12608 [INFO ] - VERBOSE: Exporting function 'Uninstall-ChocolateyZipPackage'.
2020-05-26 10:01:27,813 12608 [INFO ] - VERBOSE: Exporting function 'Update-SessionEnvironment'.
2020-05-26 10:01:27,813 12608 [INFO ] - VERBOSE: Exporting function 'Write-ChocolateyFailure'.
2020-05-26 10:01:27,813 12608 [INFO ] - VERBOSE: Exporting function 'Write-ChocolateySuccess'.
2020-05-26 10:01:27,814 12608 [INFO ] - VERBOSE: Exporting function 'Write-FileUpdateLog'.
2020-05-26 10:01:27,814 12608 [INFO ] - VERBOSE: Exporting function 'Write-FunctionCallLogMessage'.
2020-05-26 10:01:27,814 12608 [INFO ] - VERBOSE: Exporting function 'Get-AppInstallLocation'.
2020-05-26 10:01:27,815 12608 [INFO ] - VERBOSE: Exporting function 'Get-AvailableDriveLetter'.
2020-05-26 10:01:27,815 12608 [INFO ] - VERBOSE: Exporting function 'Get-EffectiveProxy'.
2020-05-26 10:01:27,815 12608 [INFO ] - VERBOSE: Exporting function 'Get-PackageCacheLocation'.
2020-05-26 10:01:27,816 12608 [INFO ] - VERBOSE: Exporting function 'Get-WebContent'.
2020-05-26 10:01:27,816 12608 [INFO ] - VERBOSE: Exporting function 'Register-Application'.
2020-05-26 10:01:27,816 12608 [INFO ] - VERBOSE: Exporting function 'Remove-Process'.
2020-05-26 10:01:27,817 12608 [INFO ] - VERBOSE: Exporting function 'Install-DotNetDevPack'.
2020-05-26 10:01:27,817 12608 [INFO ] - VERBOSE: Exporting function 'Install-DotNetFramework'.
2020-05-26 10:01:27,817 12608 [INFO ] - VERBOSE: Exporting function 'Install-WindowsUpdate'.
2020-05-26 10:01:27,818 12608 [INFO ] - VERBOSE: Exporting function 'Test-WindowsUpdate'.
2020-05-26 10:01:27,818 12608 [INFO ] - VERBOSE: Exporting alias 'Get-ProcessorBits'.
2020-05-26 10:01:27,818 12608 [INFO ] - VERBOSE: Exporting alias 'Get-OSBitness'.
2020-05-26 10:01:27,819 12608 [INFO ] - VERBOSE: Exporting alias 'Get-InstallRegistryKey'.
2020-05-26 10:01:27,819 12608 [INFO ] - VERBOSE: Exporting alias 'Generate-BinFile'.
2020-05-26 10:01:27,819 12608 [INFO ] - VERBOSE: Exporting alias 'Add-BinFile'.
2020-05-26 10:01:27,820 12608 [INFO ] - VERBOSE: Exporting alias 'Start-ChocolateyProcess'.
2020-05-26 10:01:27,820 12608 [INFO ] - VERBOSE: Exporting alias 'Invoke-ChocolateyProcess'.
2020-05-26 10:01:27,820 12608 [INFO ] - VERBOSE: Exporting alias 'Remove-BinFile'.
2020-05-26 10:01:27,827 12608 [INFO ] - VERBOSE: Exporting alias 'refreshenv'.
2020-05-26 10:01:27,827 12608 [INFO ] - VERBOSE: Importing function 'Format-FileSize'.
2020-05-26 10:01:27,827 12608 [INFO ] - VERBOSE: Importing function 'Get-AppInstallLocation'.
2020-05-26 10:01:27,828 12608 [INFO ] - VERBOSE: Importing function 'Get-AvailableDriveLetter'.
2020-05-26 10:01:27,828 12608 [INFO ] - VERBOSE: Importing function 'Get-ChecksumValid'.
2020-05-26 10:01:27,829 12608 [INFO ] - VERBOSE: Importing function 'Get-ChocolateyUnzip'.
2020-05-26 10:01:27,829 12608 [INFO ] - VERBOSE: Importing function 'Get-ChocolateyWebFile'.
2020-05-26 10:01:27,829 12608 [INFO ] - VERBOSE: Importing function 'Get-EffectiveProxy'.
2020-05-26 10:01:27,830 12608 [INFO ] - VERBOSE: Importing function 'Get-EnvironmentVariable'.
2020-05-26 10:01:27,830 12608 [INFO ] - VERBOSE: Importing function 'Get-EnvironmentVariableNames'.
2020-05-26 10:01:27,830 12608 [INFO ] - VERBOSE: Importing function 'Get-FtpFile'.
2020-05-26 10:01:27,831 12608 [INFO ] - VERBOSE: Importing function 'Get-OSArchitectureWidth'.
2020-05-26 10:01:27,831 12608 [INFO ] - VERBOSE: Importing function 'Get-PackageCacheLocation'.
2020-05-26 10:01:27,832 12608 [INFO ] - VERBOSE: Importing function 'Get-PackageParameters'.
2020-05-26 10:01:27,832 12608 [INFO ] - VERBOSE: Importing function 'Get-PackageParametersBuiltIn'.
2020-05-26 10:01:27,832 12608 [INFO ] - VERBOSE: Importing function 'Get-ToolsLocation'.
2020-05-26 10:01:27,833 12608 [INFO ] - VERBOSE: Importing function 'Get-UACEnabled'.
2020-05-26 10:01:27,833 12608 [INFO ] - VERBOSE: Importing function 'Get-UninstallRegistryKey'.
2020-05-26 10:01:27,833 12608 [INFO ] - VERBOSE: Importing function 'Get-VirusCheckValid'.
2020-05-26 10:01:27,834 12608 [INFO ] - VERBOSE: Importing function 'Get-WebContent'.
2020-05-26 10:01:27,834 12608 [INFO ] - VERBOSE: Importing function 'Get-WebFile'.
2020-05-26 10:01:27,834 12608 [INFO ] - VERBOSE: Importing function 'Get-WebFileName'.
2020-05-26 10:01:27,835 12608 [INFO ] - VERBOSE: Importing function 'Get-WebHeaders'.
2020-05-26 10:01:27,835 12608 [INFO ] - VERBOSE: Importing function 'Install-BinFile'.
2020-05-26 10:01:27,835 12608 [INFO ] - VERBOSE: Importing function 'Install-ChocolateyDesktopLink'.
2020-05-26 10:01:27,836 12608 [INFO ] - VERBOSE: Importing function 'Install-ChocolateyEnvironmentVariable'.
2020-05-26 10:01:27,836 12608 [INFO ] - VERBOSE: Importing function 'Install-ChocolateyExplorerMenuItem'.
2020-05-26 10:01:27,836 12608 [INFO ] - VERBOSE: Importing function 'Install-ChocolateyFileAssociation'.
2020-05-26 10:01:27,837 12608 [INFO ] - VERBOSE: Importing function 'Install-ChocolateyInstallPackage'.
2020-05-26 10:01:27,837 12608 [INFO ] - VERBOSE: Importing function 'Install-ChocolateyPackage'.
2020-05-26 10:01:27,837 12608 [INFO ] - VERBOSE: Importing function 'Install-ChocolateyPath'.
2020-05-26 10:01:27,838 12608 [INFO ] - VERBOSE: Importing function 'Install-ChocolateyPinnedTaskBarItem'.
2020-05-26 10:01:27,838 12608 [INFO ] - VERBOSE: Importing function 'Install-ChocolateyPowershellCommand'.
2020-05-26 10:01:27,838 12608 [INFO ] - VERBOSE: Importing function 'Install-ChocolateyShortcut'.
2020-05-26 10:01:27,839 12608 [INFO ] - VERBOSE: Importing function 'Install-ChocolateyVsixPackage'.
2020-05-26 10:01:27,839 12608 [INFO ] - VERBOSE: Importing function 'Install-ChocolateyZipPackage'.
2020-05-26 10:01:27,839 12608 [INFO ] - VERBOSE: Importing function 'Install-DotNetDevPack'.
2020-05-26 10:01:27,840 12608 [INFO ] - VERBOSE: Importing function 'Install-DotNetFramework'.
2020-05-26 10:01:27,840 12608 [INFO ] - VERBOSE: Importing function 'Install-Vsix'.
2020-05-26 10:01:27,840 12608 [INFO ] - VERBOSE: Importing function 'Install-WindowsUpdate'.
2020-05-26 10:01:27,841 12608 [INFO ] - VERBOSE: Importing function 'Register-Application'.
2020-05-26 10:01:27,841 12608 [INFO ] - VERBOSE: Importing function 'Remove-Process'.
2020-05-26 10:01:27,841 12608 [INFO ] - VERBOSE: Importing function 'Set-EnvironmentVariable'.
2020-05-26 10:01:27,842 12608 [INFO ] - VERBOSE: Importing function 'Set-PowerShellExitCode'.
2020-05-26 10:01:27,842 12608 [INFO ] - VERBOSE: Importing function 'Start-ChocolateyProcessAsAdmin'.
2020-05-26 10:01:27,842 12608 [INFO ] - VERBOSE: Importing function 'Test-ProcessAdminRights'.
2020-05-26 10:01:27,842 12608 [INFO ] - VERBOSE: Importing function 'Test-WindowsUpdate'.
2020-05-26 10:01:27,843 12608 [INFO ] - VERBOSE: Importing function 'Uninstall-BinFile'.
2020-05-26 10:01:27,843 12608 [INFO ] - VERBOSE: Importing function 'Uninstall-ChocolateyEnvironmentVariable'.
2020-05-26 10:01:27,843 12608 [INFO ] - VERBOSE: Importing function 'Uninstall-ChocolateyPackage'.
2020-05-26 10:01:27,844 12608 [INFO ] - VERBOSE: Importing function 'Uninstall-ChocolateyZipPackage'.
2020-05-26 10:01:27,844 12608 [INFO ] - VERBOSE: Importing function 'Update-SessionEnvironment'.
2020-05-26 10:01:27,844 12608 [INFO ] - VERBOSE: Importing function 'Write-ChocolateyFailure'.
2020-05-26 10:01:27,845 12608 [INFO ] - VERBOSE: Importing function 'Write-ChocolateySuccess'.
2020-05-26 10:01:27,845 12608 [INFO ] - VERBOSE: Importing function 'Write-FileUpdateLog'.
2020-05-26 10:01:27,845 12608 [INFO ] - VERBOSE: Importing function 'Write-FunctionCallLogMessage'.
2020-05-26 10:01:27,846 12608 [INFO ] - VERBOSE: Importing alias 'Add-BinFile'.
2020-05-26 10:01:27,846 12608 [INFO ] - VERBOSE: Importing alias 'Generate-BinFile'.
2020-05-26 10:01:27,846 12608 [INFO ] - VERBOSE: Importing alias 'Get-InstallRegistryKey'.
2020-05-26 10:01:27,847 12608 [INFO ] - VERBOSE: Importing alias 'Get-OSBitness'.
2020-05-26 10:01:27,847 12608 [INFO ] - VERBOSE: Importing alias 'Get-ProcessorBits'.
2020-05-26 10:01:27,847 12608 [INFO ] - VERBOSE: Importing alias 'Invoke-ChocolateyProcess'.
2020-05-26 10:01:27,848 12608 [INFO ] - VERBOSE: Importing alias 'refreshenv'.
2020-05-26 10:01:27,848 12608 [INFO ] - VERBOSE: Importing alias 'Remove-BinFile'.
2020-05-26 10:01:27,848 12608 [INFO ] - VERBOSE: Importing alias 'Start-ChocolateyProcess'.
2020-05-26 10:01:27,870 12608 [DEBUG] - ---------------------------Script Execution---------------------------
2020-05-26 10:01:27,870 12608 [DEBUG] - Running 'ChocolateyScriptRunner' for gsudo v0.7.0 with packageScript 'C:\ProgramData\chocolatey\lib\gsudo\tools\chocolateyinstall.ps1', packageFolder:'C:\ProgramData\chocolatey\lib\gsudo', installArguments: '', packageParameters: '',
2020-05-26 10:01:27,875 12608 [DEBUG] - Running 'C:\ProgramData\chocolatey\lib\gsudo\tools\chocolateyinstall.ps1'
2020-05-26 10:01:27,903 12608 [DEBUG] - Running Install-ChocolateyPath -pathToInstall 'C:\ProgramData\chocolatey\lib\gsudo\bin\' -pathType 'User' 
2020-05-26 10:01:27,906 12608 [DEBUG] - Running Update-SessionEnvironment 
2020-05-26 10:01:27,907 12608 [INFO ] - VERBOSE: Refreshing environment variables from the registry.
2020-05-26 10:01:28,006 12608 [INFO ] - PATH environment variable does not have C:\ProgramData\chocolatey\lib\gsudo\bin\ in it. Adding...
2020-05-26 10:01:28,007 12608 [INFO ] - VERBOSE: Choosing not to expand environment names
2020-05-26 10:01:28,022 12608 [DEBUG] - Running Set-EnvironmentVariable -Name 'Path' -Value 'C:\Users\admin\AppData\Local\Microsoft\WindowsApps;C:\ProgramData\chocolatey\lib\gsudo\bin\;' -Scope 'User' 
2020-05-26 10:01:28,030 12608 [DEBUG] - Registry type for Path is/will be String
2020-05-26 10:01:28,038 12608 [DEBUG] - 
using System;
using System.Runtime.InteropServices;

namespace Win32
{
    public class NativeMethods
    {
    [DllImport("user32.dll", SetLastError = true, CharSet = CharSet.Auto)]
public static extern IntPtr SendMessageTimeout(
    IntPtr hWnd, uint Msg, UIntPtr wParam, string lParam,
    uint fuFlags, uint uTimeout, out UIntPtr lpdwResult);

    }

}

2020-05-26 10:01:28,959 12608 [DEBUG] - Running Update-SessionEnvironment 
2020-05-26 10:01:28,960 12608 [INFO ] - VERBOSE: Refreshing environment variables from the registry.
2020-05-26 10:01:28,997 12608 [INFO ] - symbolische Verknüpfung erstellt für C:\ProgramData\chocolatey\lib\gsudo\bin\\sudo.exe <<===>> C:\ProgramData\chocolatey\lib\gsudo\bin\\gsudo.exe
2020-05-26 10:01:28,999 12608 [INFO ] - Done.
2020-05-26 10:01:29,005 12608 [DEBUG] - ----------------------------------------------------------------------
2020-05-26 10:01:29,007 12608 [DEBUG] - Built-in PowerShell host called with ['[System.Threading.Thread]::CurrentThread.CurrentCulture = '';[System.Threading.Thread]::CurrentThread.CurrentUICulture = ''; & import-module -name 'C:\ProgramData\chocolatey\helpers\chocolateyInstaller.psm1'; & 'C:\ProgramData\chocolatey\helpers\chocolateyScriptRunner.ps1' -packageScript 'C:\ProgramData\chocolatey\lib\gsudo\tools\chocolateyinstall.ps1' -installArguments '' -packageParameters '''] exited with '0'.
2020-05-26 10:01:29,009 12608 [DEBUG] - Calling command ['"C:\windows\System32\shutdown.exe" /a']
2020-05-26 10:01:29,030 12608 [DEBUG] - Command ['"C:\windows\System32\shutdown.exe" /a'] exited with '1116'
2020-05-26 10:01:29,039 12608 [WARN ] - Environment Vars (like PATH) have changed. Close/reopen your shell to
 see the changes (or in powershell/cmd.exe just type `refreshenv`).
2020-05-26 10:01:29,040 12608 [DEBUG] - Logging of values is not turned on by default because it
 could potentially expose sensitive data. If you understand the risk,
 please see `choco feature -h` for information to turn it on.
2020-05-26 10:01:29,041 12608 [DEBUG] - The following values have been added/changed (may contain sensitive data):
2020-05-26 10:01:29,041 12608 [DEBUG] -   * Path='[REDACTED]' (User)
2020-05-26 10:01:29,041 12608 [DEBUG] -   * ChocolateyLastPathUpdate='[REDACTED]' (User)
2020-05-26 10:01:29,069 12608 [DEBUG] - Capturing package files in 'C:\ProgramData\chocolatey\lib\gsudo'
2020-05-26 10:01:29,071 12608 [DEBUG] -  Found 'C:\ProgramData\chocolatey\lib\gsudo\gsudo.nupkg'
  with checksum 'A5A3D55486E6E2701C1706136BD04FB1'
2020-05-26 10:01:29,072 12608 [DEBUG] -  Found 'C:\ProgramData\chocolatey\lib\gsudo\gsudo.nuspec'
  with checksum '54681F0083B1C297EB40D56188E43BE2'
2020-05-26 10:01:29,073 12608 [DEBUG] -  Found 'C:\ProgramData\chocolatey\lib\gsudo\bin\gsudo.exe'
  with checksum 'F85D06A7FB4074CF5994CC217863EC6B'
2020-05-26 10:01:29,073 12608 [DEBUG] -  Found 'C:\ProgramData\chocolatey\lib\gsudo\bin\gsudo.exe.ignore'
  with checksum 'D41D8CD98F00B204E9800998ECF8427E'
2020-05-26 10:01:29,074 12608 [DEBUG] -  Found 'C:\ProgramData\chocolatey\lib\gsudo\bin\sudo.exe'
  with checksum 'F85D06A7FB4074CF5994CC217863EC6B'
2020-05-26 10:01:29,074 12608 [DEBUG] -  Found 'C:\ProgramData\chocolatey\lib\gsudo\bin\sudo.exe.ignore'
  with checksum 'D41D8CD98F00B204E9800998ECF8427E'
2020-05-26 10:01:29,075 12608 [DEBUG] -  Found 'C:\ProgramData\chocolatey\lib\gsudo\tools\chocolateybeforemodify.ps1'
  with checksum '01F6D608DE02EE0D739A996818FFC664'
2020-05-26 10:01:29,076 12608 [DEBUG] -  Found 'C:\ProgramData\chocolatey\lib\gsudo\tools\chocolateyinstall.ps1'
  with checksum '03998BF901F6C2C60D148DB17075743B'
2020-05-26 10:01:29,077 12608 [DEBUG] -  Found 'C:\ProgramData\chocolatey\lib\gsudo\tools\chocolateyuninstall.ps1'
  with checksum '3C55ED39F08A67A8A2537A5513860360'
2020-05-26 10:01:29,077 12608 [DEBUG] -  Found 'C:\ProgramData\chocolatey\lib\gsudo\tools\LICENSE.txt'
  with checksum 'F5F8DE654F0576F6C48F8A77C5C4DEB0'
2020-05-26 10:01:29,078 12608 [DEBUG] -  Found 'C:\ProgramData\chocolatey\lib\gsudo\tools\Uninstall-ChocolateyPath.psm1'
  with checksum '94D45277C665091D222FA49A2BF87844'
2020-05-26 10:01:29,078 12608 [DEBUG] -  Found 'C:\ProgramData\chocolatey\lib\gsudo\tools\VERIFICATION.txt'
  with checksum 'E23D84142C2E803B19ADDF0BEFB68CD7'
2020-05-26 10:01:29,096 12608 [DEBUG] - Attempting to delete file "C:\ProgramData\chocolatey\.chocolatey\gsudo.0.7.0\.arguments".
2020-05-26 10:01:29,097 12608 [DEBUG] - Attempting to delete file "C:\ProgramData\chocolatey\.chocolatey\gsudo.0.7.0\.extra".
2020-05-26 10:01:29,097 12608 [DEBUG] - Attempting to delete file "C:\ProgramData\chocolatey\.chocolatey\gsudo.0.7.0\.version".
2020-05-26 10:01:29,098 12608 [DEBUG] - Attempting to delete file "C:\ProgramData\chocolatey\.chocolatey\gsudo.0.7.0\.sxs".
2020-05-26 10:01:29,098 12608 [DEBUG] - Attempting to delete file "C:\ProgramData\chocolatey\.chocolatey\gsudo.0.7.0\.pin".
2020-05-26 10:01:29,099 12608 [DEBUG] - Sending message 'HandlePackageResultCompletedMessage' out if there are subscribers...
2020-05-26 10:01:29,100 12608 [DEBUG] - Attempting to delete file "C:\ProgramData\chocolatey\lib\gsudo\.chocolateyPending".
2020-05-26 10:01:29,102 12608 [INFO ] -  The install of gsudo was successful.
2020-05-26 10:01:29,104 12608 [INFO ] -   Software install location not explicitly set, could be in package or
  default install location if installer.
2020-05-26 10:01:29,107 12608 [DEBUG] - Attempting to delete file "C:\Users\admin\AppData\Local\NuGet\Cache\gsudo.0.7.0.nupkg".
2020-05-26 10:01:29,112 12608 [WARN ] - 
Chocolatey installed 1/1 packages. 
 See the log for details (C:\ProgramData\chocolatey\logs\chocolatey.log).
2020-05-26 10:01:29,115 12608 [DEBUG] - Sending message 'PostRunMessage' out if there are subscribers...
2020-05-26 10:01:29,125 12608 [DEBUG] - Exiting with 0
black-snow commented 4 years ago

It seems like C:\ProgramData\chocolatey\lib\gsudo\bin\ is not added to my path.

My path has C:\ProgramData\chocolatey\bin maybe gsudo should go there. This is where other things go, too. There's my 7z, ant, etc.

black-snow commented 4 years ago

Added the above to my path, works fine now.

gerardog commented 4 years ago

Glad to hear you figured it out. The installer adds gsudo to the PATH here Your log shows that code ran:


2020-05-26 10:01:27,903 12608 [DEBUG] - Running Install-ChocolateyPath -pathToInstall 'C:\ProgramData\chocolatey\lib\gsudo\bin\' -pathType 'User' 
(...)
2020-05-26 10:01:28,022 12608 [DEBUG] - Running Set-EnvironmentVariable -Name 'Path' -Value 'C:\Users\admin\AppData\Local\Microsoft\WindowsApps;C:\ProgramData\chocolatey\lib\gsudo\bin\;' -Scope 'User' 
2020-05-26 10:01:28,030 12608 [DEBUG] - Registry type for Path is/will be String

I found unusual the path includes "C:\Users\admin\AppData\Local\Microsoft\WindowsApps" Your command line shows you have not done two installs on one line like choco install WindowsTerminal gsudo... (EDIT: nevermind, you probable redacted it)

On all tests I've done, the path variable is set correctly. I will close this as you've figured it out but will keep an eye on similar reports or when retesting the choco package. Thanks for reporting.

gerardog commented 4 years ago

One more question, does your regular user has admin privileges? or do you have separated non-admin and admin users?

black-snow commented 4 years ago

@gerardog there's a separate admin user and that's where the path was added to the path (sic!). Maybe it should be added to all users' paths or system path - it's installed for all users after all, isn't it?

Thanks for looking into this!

baltermia commented 1 year ago

For me the added Path in the PATH env-variable was C:\Program Files\gsudo\Current. The exe-files were in a folder named after the version though, which lead to problems, so I also added another PATH to C:\Program Files\gsudo\X.Y.Z where XYZ is the version number.

gerardog commented 1 year ago

Hi @baltermia. Have you restarted your consoles for the PATH variable change to apply? This is the 99.9% reason why gsudo is not found after install.

The application is intentionally deploying to the specific version folder C:\Program Files\gsudo\X.Y.Z, and creating a C:\Program Files\gsudo\Current which is a link (directory junction) to X.Y.Z image

Your C:\Program Files\gsudo\Current should be a junction, not a regular folder. Please confirm. You can see that with the command line shown above or with Windows Explorer... In Windows 10 looks like this: (notice the arrow in the Current icon) image

This is intentonall and allows you to install a new gsudo version when the previous version is still running.

baltermia commented 1 year ago

Hi @gerardog thanks for the reply.

I looked for the Current junction, but I could ot find it: image

It's nowhere to be found, so it seems to me that it didn't get created during the installation process.

I manually created the Current junction and deleted the old entry in the PATH variable. image

gerardog commented 1 year ago

Mmm... I don't know why the Current directory junction failed to create. That is worth investigating.

Your link has a .lnk extension... may not be valid for our purposes.

here is the creation of the directory junction:

cmd /c mklink /J "[INSTALLFOLDER]Current" "[VERSIONFOLDER]"

which should translate to

cmd /c mklink /J "C:\Program Files\gsudo\Current" "c:\Program Files\gsudo\2.3.0"

baltermia commented 1 year ago

Do you have a incorrect folder named c:\Program Files\gsudoCurrent folder ? (gsudo and current intentionally badly joined) There is no other folder expect gsudo.

can you run cmd /c mklink /J "c:\Program Files\gsudo\Current" "c:\Program Files\gsudo\2.3.0"? as admin ? Confirm if that creates the link please.

That worked, everything's fine now thanks a bunch!

Also quick question, sudo does not seem to work, only gsudo. Is there a way I can activate the sudo command aswell? My other machine has that working fine.