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

Add attrs like directory path to registry list output. #4069

Closed
wants to merge 1 commit into from

Conversation

@kquick
Copy link
Contributor

@kquick kquick commented Sep 25, 2020

The registry targets can have associated attributes (e.g. github.com/owner/repo?dir=subdir/in/repo) but the attributes are not displayed on a registry listing. They are currently only visible via the $ nix flake info flake:foo command, but if there is a problem with the registry entry, an error is displayed without any local information. It is sometimes possible to extract the attribute from the error message, but since the attributes are local information that doesn't depend on the remote object, they should be visible independently of success in accessing the remote object.

This can also cause confusion about the registry support for these attributes (see issue #4050).

This patch adds the display of the attributes to the registry list command. At present, the only attribute I'm aware of is the "dir" attribute; in the future it may be appropriate to add filtering if there are attributes that should not be visible.

@edolstra
Copy link
Member

@edolstra edolstra commented Sep 29, 2020

Thanks! I've fixed this in a slightly different way (namely making nix registry list do basically the same thing as FlakeRef::to_string()). (64e9b3c)

@edolstra edolstra closed this Sep 29, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

2 participants