xatupal / KeeTheme

KeePass Plugin
MIT License
457 stars 36 forks source link

choco install fails when existing keepass installed via scoop #62

Closed mockuser404 closed 2 years ago

mockuser404 commented 3 years ago

keypass is in the extras bucket for scoop.sh

I installed keepass via scoop scoop install keepass

I tried to install this tool as mentioned in the readme via chocolatey (powershell admin)

choco install keepass-plugin-keetheme

Chocolatey v0.10.15
Installing the following packages:
keepass-plugin-keetheme
By installing you accept licenses for the packages.
Progress: Downloading keepass 2.49... 100%
Progress: Downloading keepass.install 2.49... 100%
Progress: Downloading keepass-plugin-keetheme 0.9.2... 100%

keepass.install v2.49 [Approved]
keepass.install package files install completed. Performing other installation steps.
Installing keepass.install...
ERROR: Running ["C:\ProgramData\chocolatey\lib\keepass.install\tools\KeePass-Setup.exe" /VERYSILENT /SUPPRESSMSGBOXES /NORESTART /SP- ] was not successful. Exit code was '1'. See log for possible error messages.
The install of keepass.install was NOT successful.
Error while running 'C:\ProgramData\chocolatey\lib\keepass.install\tools\chocolateyInstall.ps1'.
 See log for details.

keepass v2.49 [Approved]
keepass package files install completed. Performing other installation steps.
 The install of keepass was successful.
  Software install location not explicitly set, could be in package or
  default install location if installer.

keepass-plugin-keetheme v0.9.2 [Approved]
keepass-plugin-keetheme package files install completed. Performing other installation steps.
Get-BinRoot is going to be deprecated in v1 and removed in v2. It has been replaced with Get-ToolsLocation (starting with v0.9.10), however many packages no longer require a special separate directory since package folders no longer have versions on them. Some do though and should continue to use Get-ToolsLocation.
Cannot find path 'C:\WINDOWS\system32\-ErrorAction' because it does not exist.
Cannot find path 'C:\WINDOWS\system32\SilentlyContinue' because it does not exist.
WARNING: KeePass Password Safe not found.
ERROR: ScriptHalted
The install of keepass-plugin-keetheme was NOT successful.
Error while running 'C:\ProgramData\chocolatey\lib\keepass-plugin-keetheme\tools\chocolateyinstall.ps1'.
 See log for details.

Chocolatey installed 1/3 packages. 2 packages failed.
 See the log for details (C:\ProgramData\chocolatey\logs\chocolatey.log).

Failures
 - keepass.install (exited 1) - Error while running 'C:\ProgramData\chocolatey\lib\keepass.install\tools\chocolateyInstall.ps1'.
 See log for details.
 - keepass-plugin-keetheme (exited -1) - Error while running 'C:\ProgramData\chocolatey\lib\keepass-plugin-keetheme\tools\chocolateyinstall.ps1'.
 See log for details.

I cannot attach the full chocolatey log but the relevant lines were

2021-10-28 23:25:01,654 12816 [DEBUG] - Running 'ChocolateyScriptRunner' for keepass-plugin-keetheme v0.9.2 with packageScript 'C:\ProgramData\chocolatey\lib\keepass-plugin-keetheme\tools\chocolateyinstall.ps1', packageFolder:'C:\ProgramData\chocolatey\lib\keepass-plugin-keetheme', installArguments: '', packageParameters: '',
2021-10-28 23:25:01,655 12816 [DEBUG] - Running 'C:\ProgramData\chocolatey\lib\keepass-plugin-keetheme\tools\chocolateyinstall.ps1'
2021-10-28 23:25:01,681 12816 [INFO ] - VERBOSE: Searching registry for installed KeePass...
2021-10-28 23:25:02,299 12816 [INFO ] - VERBOSE: Searching  for portable install...
2021-10-28 23:25:02,330 12816 [INFO ] - VERBOSE: Searching C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\WINDOWS\System32\OpenSSH\;C:\ProgramData\chocolatey\bin;C:\Program Files\Intel\WiFi\bin\;C:\Program Files\Common Files\Intel\WirelessCommon\;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;D:\Software\vcpkg;C:\Users\<UserName>\scoop\shims;C:\Users\<UserName>\scoop\apps\keepass\current;C:\Users\<UserName>\.local\bin;C:\Users\<UserName>\go\bin; for unregistered install...
2021-10-28 23:25:02,368 12816 [WARN ] - WARNING: KeePass Password Safe not found.
2021-10-28 23:25:02,370 12816 [ERROR] - ERROR: ScriptHalted

There is however a keepass.exe in my PATH C:\Users\<UserName>\scoop\apps\keepass\current\KeePass.exe

mockuser404 commented 3 years ago

My temporary workaround is uninstall scoop version and run the command, it succeeds like intended and installs keepass.

xatupal commented 2 years ago

Thanks for pointing out the issue and for the detailed description. Fixed.