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-info: init #30397
nix-info: init #30397
Conversation
|
pkgs/tools/nix/help/help.sh
Outdated
} | ||
|
||
desc_multi_user() { | ||
if test -e /nix/var/nix/daemon-socket; then |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I just realised that this will probably always exist on darwin, unless nix was installed before the multi-user installer.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I feel okay with this, but if there is a good fix / improvement I'd be happy to do that
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What about also checking test $NIX_REMOTE = daemon
and printing unknown instead if the results are inconsistent
dbfdd67
to
8dc07e5
Compare
grahamc@Morbo> ./result/bin/nix-help -m
|
How about naming it |
done, @Mic92 |
I included nix-info in to the default closure per @LnL7's suggestion. |
e0757d5
to
cc2f1d6
Compare
Two outputs: $ ./result/bin/nix-info
$ ./result/bin/nix-info -m
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nice!
It might be useful to include |
Hmm I was thinking u name would be sufficient for that, as it provides the
distro they’re on, and I’m not certain the utility of the specific distro
version. Except for NixOS, which we can tell from the channel. Does that
make sense? Would it make more sense to drop uname and use $VERSION instead?
…On Sat, Oct 14, 2017 at 7:24 AM zimbatm ***@***.***> wrote:
It might be useful to include source /etc/os-release && echo $VERSION to
the report. Most linux systems are migrating to this new standard:
https://www.freedesktop.org/software/systemd/man/os-release.html
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#30397 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AAErrEz3s-s3ollJ18vnPysv9JugcLaVks5ssJoJgaJpZM4P5C35>
.
|
7ca954d
to
74f39be
Compare
Updated: it now performs conclusive sandboxing and multi-user testing by running nix builds. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great! Works for me on NixOS.
If this change was back-ported to 17.09 (and 17.03?) then it can be used for issues reporting more reliably. |
Wouldn't it be better to include something like this in Nix itself? |
On the long term maybe, but it could take a while until we have a new nix version. |
I don't think adding a separate command is the way to go, because then we would need to tell people to install a separate package just to get some trivial bits of info that Nix can easily provide. (E.g. why run IMHO it would be better to expand the output of |
@edolstra the reason I didn't propose this in core Nix is the lifecycle. If we determine there is something useless in this command, or more important information, it takes just a couple days to update it. I would prefer it be in core Nix, but I think it would be helpful to mature the tool for a bit. That said, I agree: making the nix tool better at describing itself is a good idea, and we could use that information to remove some of the sillier things this tool does to work. |
I thought that it was obvious that it would be integrated into nix in the long run. Nixpkgs is much more amenable to change and experiment by the community. Once the command has stabilized it will be easy enough to implement an optimized version inside of nix directly. |
I'll send a PR updating the issue template soon. |
Motivation for this change
Create a one-liner output to help diagnose systems on IRC:
Things done
build-use-sandbox
innix.conf
on non-NixOS)./result/bin/
)