Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Using WinGet to install package from Windows Terminal in Non-Admin mode causes Command-line alias creation to silently fail #3436

Closed
philip-young opened this issue Jul 14, 2023 · 4 comments
Labels
Portable Issue related to portable package Resolution-Duplicate Issue is a duplicate
Milestone

Comments

@philip-young
Copy link

philip-young commented Jul 14, 2023

Brief description of your issue

I tried to install mkcert from winget using the Windows Terminal in non-Admin mode. It seems that even though the package was created successfully, the line indicating that a command line alias was created didn't work. I double checked my PATH environment variable and that correctly was created and pointed to the path of where the package was installed, but when I tried to run the package using the alias 'mkcert' I got an error indicating it couldn't be found.

Eventually I tried running Windows Terminal in Administrator mode and reinstalled the package and it worked.

image

Steps to reproduce

In Windows Terminal (non Admin):
winget install mkcert
Install successful and command line alias added.
Restart Terminal to load new environment variables.

mkcert

(error not found)

Expected behavior

using the mkcert alias from the command line works successfully.

Actual behavior

the newly installed package is not found when using the alias, but when using the package name mkcert-xxx-windows-amd64.exe it is found.

Environment

Windows Package Manager v1.5.1572
Copyright (c) Microsoft Corporation. All rights reserved.

Windows: Windows.Desktop v10.0.22621.1848
System Architecture: X64
Package: Microsoft.DesktopAppInstaller v1.20.1572.0
@microsoft-github-policy-service microsoft-github-policy-service bot added the Needs-Triage Issue need to be triaged label Jul 14, 2023
@mdanish-kh
Copy link
Contributor

This is because the exe full name is mkcert-v1.4.4-windows-amd64.exe and looks like WinGet doesn't rename portables in non-symlinked installations. Not sure if this bug is being tracked separately here in the CLI.

Similar case to microsoft/winget-pkgs#111454

[Policy] Portable

@mdanish-kh
Copy link
Contributor

mdanish-kh commented Jul 14, 2023

I'll mark this as duplicate of the newly created issue for better tracking of the underlying issue

Duplicate of #3437

@microsoft-github-policy-service
Copy link
Contributor

Hello @philip-young,

We've identified this as a duplicate of another issue or PR that already exists. This specific instance is being closed in favor of the linked issue. Please add your 👍 to the other issue to raise its priority. Thanks for your contribution!

Template: msftbot/duplicate/closed

@microsoft-github-policy-service microsoft-github-policy-service bot added Resolution-Duplicate Issue is a duplicate and removed Needs-Triage Issue need to be triaged labels Jul 14, 2023
@microsoft-github-policy-service
Copy link
Contributor

Hello @philip-young,

We've identified this as a duplicate of another issue or PR that already exists. This specific instance is being closed in favor of the linked issue. Please add your 👍 to the other issue to raise its priority. Thanks for your contribution!

Template: msftbot/duplicate/closed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Portable Issue related to portable package Resolution-Duplicate Issue is a duplicate
Projects
None yet
Development

No branches or pull requests

3 participants