microsoft / winget-pkgs

The Microsoft community Windows Package Manager manifest repository
MIT License
8.57k stars 4.46k forks source link

AutoHotKey not completing installation #155172

Open akulbe opened 4 months ago

akulbe commented 4 months ago

https://github.com/microsoft/winget-pkgs/blob/8b576831a27c7d44ef1fd3e25de52d1d1a52790e/manifests/a/AutoHotkey/AutoHotkey/2.0.15/AutoHotkey.AutoHotkey.installer.yaml#L13

After installing 2.0.15 with winget there is no folder in "Program Files".

Is this because there's no actual install path specified? Am I reading that right?

SpecterShell commented 4 months ago

That switch will not be used unless you specify the install destination by using the -l or --location switches from WinGet. In user scope the program will be installed to %LOCALAPPDATA%\Programs\AutoHotkey by default.

akulbe commented 4 months ago

Shouldn’t the application still end up on $PATH though?

On Sat, May 25, 2024 at 17:09 Charlie Chen @.***> wrote:

That switch will not be used unless you specify the install destination by using the -l or --location switches from WinGet. In user scope the program will be installed to %LOCALAPPDATA%\Programs\AutoHotkey by default.

— Reply to this email directly, view it on GitHub https://github.com/microsoft/winget-pkgs/issues/155172#issuecomment-2131742661, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAA6DDZCEQEEUDK2XP7PWZ3ZEER43AVCNFSM6AAAAABIJAWHEGVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCMZRG42DENRWGE . You are receiving this because you authored the thread.Message ID: @.***>

Trenly commented 4 months ago

Shouldn’t the application still end up on $PATH though?

WinGet doesn’t have the ability to add programs to PATH unless they have the installer type portable - which are loose binaries that don’t have an installer. In all other cases, it is up to the application's installer to update PATH.

akulbe commented 4 months ago

@Trenly Question. If the installer's default action is to create C:\Program Files\AutoHotkey\ and put the relevant files there, why wouldn't installing the application with winget do the same thing?

Trenly commented 4 months ago

@Trenly Question. If the installer's default action is to create C:\Program Files\AutoHotkey\ and put the relevant files there, why wouldn't installing the application with winget do the same thing?

As @spectershell mentioned, the installer puts the files in different locations depending on if itsinstalling in user scope or machine scope. If you don’t specify --scope machine, the installer will generally be executed in user scope. If you're an admin, running the installer you downloaded yourself will likely default to the machine scope

stephengillie commented 4 months ago

I tested this with https://github.com/microsoft/winget-pkgs/pull/153765 and wasn't able to verify this behavior. This package installs normally (into \Program FIles) on a Windows 10 VM:

image

The application reports missing a configuration file, but this might be normal program operation: image

Should this be tested in another way?