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

nix doctor: return nonzero exitcode if a check fails #2495

Merged
merged 1 commit into from Oct 29, 2018

Conversation

LnL7
Copy link
Member

@LnL7 LnL7 commented Oct 29, 2018

This makes it easier to use this when testing the installer or when
running the checks with other automated tooling.

This makes it easier to use this when testing the installer or when
running the checks with other automated tooling.
success &= checkStoreProtocol(store->getProtocol());

if (!success)
throw Exit(2);
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there something other than the description I can use to document this exit code?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, the nix command does not have a man page at the moment.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It would be nice to have something to provide a longer description that only shows up with nix <command> --help similar to the examples.

@edolstra edolstra merged commit f90a67e into NixOS:master Oct 29, 2018
@LnL7 LnL7 deleted the doctor-exit-code branch October 29, 2018 12:21
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

2 participants