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

Doesn't handle flake paths with "/" in the name #323

Open
kjeremy opened this issue Aug 14, 2024 · 1 comment
Open

Doesn't handle flake paths with "/" in the name #323

kjeremy opened this issue Aug 14, 2024 · 1 comment

Comments

@kjeremy
Copy link

kjeremy commented Aug 14, 2024

We have a lot of auto-generated flake names based on the scheme: "something/package-name". below we have .#cat27x/burn

$ nix flake show
...
└───packages
    └───x86_64-linux
        ├───"cat27x/burn": package 'burn.sh'
...
$ nix run nixpkgs#nix-eval-jobs -- --flake .#cat27x/burn
warning: unknown setting 'allowed-users'
warning: unknown setting 'extra-allowed-users'
warning: unknown setting 'trusted-users'
warning: `--gc-roots-dir' not specified
Using saved setting for 'extra-substituters = ssh-ng://[email protected] https://ros.cachix.org' from ~/.local/share/nix/trusted-settings.json.
Using saved setting for 'extra-trusted-public-keys = ros.cachix.org-1:dSyZxI8geDCJrwgvCOHDoAfOm5sV1wCPjBkKL+38Rvo=' from ~/.local/share/nix/trusted-settings.json.
error: flake 'git+file:///home/jkolb/ara/mrak-robot-2' does not provide attribute 'cat27x/burn'

I've also tried .#"cat27x/gcRoot" which doesn't work either.

@adisbladis
Copy link
Member

You should be able to specify the full flake attribute: .#packages.x86_64-linux.cat27x/burn.

We don't have the same packages-centric lookup where the current system is inferred.
Personally I don't think it would make sense for a tool like nix-eval jobs to have that, as it's a much more versatile and less opinionated tool than nix flake show & friends.

This discrepancy in lookups should be documented, and the error message should contain a hint that full attribute paths needs to be used.

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