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

Extension unable to find nix-shell #38

Closed
derrickbeining opened this issue Dec 12, 2020 · 4 comments
Closed

Extension unable to find nix-shell #38

derrickbeining opened this issue Dec 12, 2020 · 4 comments
Assignees
Labels
bug Something isn't working

Comments

@derrickbeining
Copy link

Describe the bug
I can't get the extension to work. It just gives me this error notification:

Command failed: nix-shell /Users/derrickbeining/Dev/ihp-app/default.nix --run env /bin/sh: nix-shell: command not found

If I go into ~/.vscode/extension/arrterian-nix-env-selector-0.1.2/out/helpers.js and replace nix-shell with the absolute path to the binary and restart vscode, then the extension works properly.

Perhaps this is just a problem with my environment, but perhaps if nix-env-selector exposed configuration to be able to specify the path to nix-shell, then that could fix my issue.

To Reproduce
Steps to reproduce the behavior:

  1. Fresh install of nix/nix-shell
  2. Fresh install of plugin
  3. Open project with default.nix expression
  4. Open command panel in VS Code and run "Nix-Env: select environment" command
  5. See error notification

Expected behavior
I expect the extension to be able to find and run nix-shell on my PATH

Environment:

  • OS: MacOS Catalina 10.15.6
  • shell: zsh
  • VS Code:
Version: 1.51.1
Commit: e5a624b788d92b8d34d1392e4c4d9789406efe8f
Date: 2020-11-11T01:11:34.018Z (1 mo ago)
Electron: 9.3.3
Chrome: 83.0.4103.122
Node.js: 12.14.1
V8: 8.3.110.13-electron.0
OS: Darwin x64 19.6.0```

 - Plugin Version: 0.1.2
@derrickbeining derrickbeining added the bug Something isn't working label Dec 12, 2020
@arrterian
Copy link
Owner

Can you check that your vscode process really has the correct path with nix-shell available? The extension can see all variables that your VSCode process.

@arrterian
Copy link
Owner

arrterian commented Dec 12, 2020

@derrickbeining

Perhaps this is just a problem with my environment, but perhaps if nix-env-selector exposed configuration to be able to specify the path to nix-shell, then that could fix my issue.

Good point BTW.

@JakubBarta
Copy link

Encountered the very same issue, the fix works for me as well.

Environment:

  • OS: Linux 5.8.18-1-MANJARO
  • shell: zsh
  • VS Code:
Version: 1.52.1
Commit: ea3859d4ba2f3e577a159bc91e3074c5d85c0523
Date: 2020-12-16T16:32:10.090Z
Electron: 9.3.5
Chrome: 83.0.4103.122
Node.js: 12.14.1
V8: 8.3.110.13-electron.0
OS: Linux x64 5.8.18-1-MANJARO snap

 - Plugin Version: 0.1.2

@arrterian
Copy link
Owner

Fixed in #44
Released in v1.0.0
Please, see CHANGELOG.md for more info.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants