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

Don't require ChocolateyInstall environment variable #427

Open
bnason-nf opened this issue Nov 4, 2020 · 1 comment
Open

Don't require ChocolateyInstall environment variable #427

bnason-nf opened this issue Nov 4, 2020 · 1 comment

Comments

@bnason-nf
Copy link

The extension currently identifies the location of the chocolatey install by looking at process.env.ChocolateyInstall. If that variable isn't set, it fails with the message "Chocolatey is not installed", even if it is installed and choco is in the path. It would be nice if it could instead just attempt to execute the choco command to see if it's in the path, or at least as a fallback if the environment variable isn't set. If this isn't desirable for some reason, maybe the error message could be improved to indicate that the environment variable needs to be set.

Thanks,
Benbuck

@JPRuskin
Copy link

JPRuskin commented Apr 1, 2022

That makes sense!

It looks like adding a bit of extra handling after checking process.env.ChocolateyInstall should make it more resilient - and there was a TODO there, anyway.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants