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

nixpkgs options autocomplete for /etc/nixos/configuration.nix #140

Open
anabelle2001 opened this issue Jun 4, 2024 · 2 comments
Open

nixpkgs options autocomplete for /etc/nixos/configuration.nix #140

anabelle2001 opened this issue Jun 4, 2024 · 2 comments

Comments

@anabelle2001
Copy link

Hello,
I've configured nil in vscode, but i don't see package options autocompleting when pressing ctrl+space to invoke intelisense while editing </etc/nixos/configuration.nix>.

I suspect this is down to misconfiguration on my own end, but I cannot tell if this is due to a misconfiguration of vscode, a misconfiguration of nil, or me misunderstanding the scope of the project. my guess is that i'm within the use case described in docs/features.md:42, but i'm honestly not 100% sure anymore. 🥴

here's a screenshot of my editor. I'm expecting to see nil populate autocomplete entries.

image

@wesdgray
Copy link

I'm looking to get this working for myself too. When looking at the release history it seems this does exist but in the notes it says it requires a working flake setup. I'm fairly new to this so I might be wrong here but that seems to imply that we would need to run the language server from a nixos system. I'm going to try to figure this out and report back, but if you figure anything out please comment back on this issue too.

@wesdgray
Copy link

@anabelle2001 I ended up giving up and installed nixd. That seemed to work for me. It did require some different setup since I am running nixos in a vm on my windows machine. I was running vscode on my windows host and using ssh to connect to my nixos vm. I needed to install vscode server on my nixos machine and ensure the nix-ide extension was installed on that nixos machine not my host machine. I also needed to ensure nixd was installed and then restart vscode.

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