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

make single installable argument optional, allowing nix log #2340

Closed

Conversation

bobvanderlinden
Copy link
Member

@bobvanderlinden bobvanderlinden commented Aug 9, 2018

Previously in Nix commands like log always required an argument. This was confusing, because it is often used in combination with nix build, but does not expect the same arguments:

$ nix build
$ nix log
error: more arguments are required
Try 'nix --help' for more information.

A workaround was to use "" as argument, since that same value is used by default for the build command:

$ nix build
$ nix log ""

This is because nix log has the following usage:

Usage: nix log <FLAGS>... <INSTALLABLE>

whereas nix build has:

Usage: nix build <FLAGS>... <INSTALLABLES>...

This PR will make the INSTALLABLE of nix log, nix eval and nix edit optional. That makes the usage as follows:

Usage: nix log <FLAGS>... <INSTALLABLE>?

Solves #2332 #2066
Partially solves #2078

@bobvanderlinden bobvanderlinden changed the title make single installable arguent optional make single installable argument optional Aug 9, 2018
@bobvanderlinden bobvanderlinden changed the title make single installable argument optional make single installable argument optional, allowing nix log Aug 9, 2018
@bobvanderlinden
Copy link
Member Author

Apparently this PR is still relevant. Could someone have a look? @NixOS/nix-core

@stale
Copy link

stale bot commented Feb 13, 2021

I marked this as stale due to inactivity. → More info

@stale stale bot added the stale label Feb 13, 2021
@bobvanderlinden
Copy link
Member Author

This was fixed according to #2066 (comment)

@stale stale bot removed the stale label Feb 14, 2021
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

Successfully merging this pull request may close these issues.

None yet

1 participant