-
Notifications
You must be signed in to change notification settings - Fork 21
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
nix-index-fork #72
base: master
Are you sure you want to change the base?
nix-index-fork #72
Conversation
I tried to build it locally and got this error: error: The option `home-manager.users.srid.programs.nix-index-fork' does not exist. Definition values:
- In `/nix/store/ry1gysi3kqddhzp7ml9arzbmb24rshyv-source/modules/home/all/terminal.nix': The {
programs = {
nix-index-fork = {
enable = true;
enableZshIntegration = true;
enableNixCommand = true;
};
};
} Not in your |
It is just standard home-manager import: nixos-config/modules/home/default.nix Line 9 in 6883459
What do you mean by imported incorrectly? The |
I got it building by disabling
I mean that it ends up looking for it at error: The option `programs.nix-index-fork2' does not exist. Definition values:
- In `/nix/store/5xavc8cqcwcm6z9ky45cif7x0vwkyxnr-source/home/shared': See the difference? Not sure how you're wiring things, but hopefully that's a hint 😄 |
The former is the correct module key, if using from I am able to get it to build by removing However, without Not sure what is going on, but from a quick look, |
Yeah that makes sense, I can look into |
Curious. Does it work if you also add |
It builds, but doesn't work (index still needs to be manually generated) |
Got it 👍🏽 I looked into I may come back to it if generating a smaller DB becomes an option, but for now I'll stick with a locally generated DB via |
That's interesting, I didn't know that. I'd very much prefer a smaller index as well, but having that automated would be great. Kind of surprised that no one has bothered to do this in I wonder if there's demand for an efficient & flake-friendly fork. |
@srid I think I got something working, if you'd like to test it, just don't use the Home Manager module from You can see the first database release on my fork here: https://github.com/gvolpe/nix-index-database/releases/tag/2024-12-22-163440 The small database is about ~17 times smaller than the full database. There's some room for improvement, but if there's enough interest, I'll work on upstreaming these changes. |
Trying with d4fe1a9 (per gvolpe/nix-index#1 (comment)) =>
Not sure what I'm missing ... |
Hmm curious if the overlay that comes with the nix-index HM module doesn't work for your multi-arch setup. Try this? nix-index-fork.package = flake.inputs.nix-index.packages.${pkgs.system}.default; |
Yeah this builds for me (also removing the nix-index-database HM module, not needed): diff --git a/modules/home/all/nix-index.nix b/modules/home/all/nix-index.nix
index ddf7bae..abebb49 100644
--- a/modules/home/all/nix-index.nix
+++ b/modules/home/all/nix-index.nix
@@ -5,19 +5,15 @@ let
inherit (flake) inputs;
in
{
- imports = [
- inputs.nix-index-database.hmModules.nix-index
- ];
-
programs = {
# Command not found handler based on nixpkgs
nix-index-fork = {
enable = true;
enableZshIntegration = true;
enableNixCommand = true;
+ package = inputs.nix-index.packages.${pkgs.system}.default;
database = inputs.nix-index-database.packages.${pkgs.system}.nix-index-small-database;
};
command-not-found.enable = false;
- # nix-index-database.comma.enable = true;
};
} |
Trying gvolpe/nix-index#1