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 flake show is cluttered with information I'm not interested in #9011

Open
bew opened this issue Sep 20, 2023 · 1 comment
Open

nix flake show is cluttered with information I'm not interested in #9011

bew opened this issue Sep 20, 2023 · 1 comment
Labels
feature Feature request or proposal

Comments

@bew
Copy link
Contributor

bew commented Sep 20, 2023

Is your feature request related to a problem? Please describe.

We had #6985 describing how nix flake show initially tried to evaluate all systems.
Now that #6988 is merged nix only evaluates the attributes for the current system (by default).

However it still clutters the output with all the systems for each top-level outputs 😠

For example nix flake show github:garnix-io/sigbovik-music will output:

github:garnix-io/sigbovik-music/ff983a1791fad30a6988f6451ac4f0726f30b2fb
├───formatter
│   ├───aarch64-darwin omitted (use '--all-systems' to show)
│   ├───aarch64-linux omitted (use '--all-systems' to show)
│   ├───x86_64-darwin omitted (use '--all-systems' to show)
│   └───x86_64-linux: package 'nixpkgs-fmt-1.3.0'
└───packages
    ├───aarch64-darwin
    │   ├───bass omitted (use '--all-systems' to show)
    │   ├───default omitted (use '--all-systems' to show)
    │   ├───melody omitted (use '--all-systems' to show)
    │   └───song omitted (use '--all-systems' to show)
    ├───aarch64-linux
    │   ├───bass omitted (use '--all-systems' to show)
    │   ├───default omitted (use '--all-systems' to show)
    │   ├───melody omitted (use '--all-systems' to show)
    │   └───song omitted (use '--all-systems' to show)
    ├───x86_64-darwin
    │   ├───bass omitted (use '--all-systems' to show)
    │   ├───default omitted (use '--all-systems' to show)
    │   ├───melody omitted (use '--all-systems' to show)
    │   └───song omitted (use '--all-systems' to show)
    └───x86_64-linux
        ├───bass: package 'sequence-of-145-notes.wav'
        ├───default: package 'garnix-music'
        ├───melody: package 'sequence-of-34-notes.wav'
        └───song: package 'overlay-of-180-notes.wav'

But I'm really only interested in my current system, all the omitted (use '--all-systems' to show) really clutters the output and makes me miss and actively search what I actually want to see! (and could directly see if this clutter wasn't there)

Describe the solution you'd like
What I'm really interested in are these lines of the output:

github:garnix-io/sigbovik-music/ff983a1791fad30a6988f6451ac4f0726f30b2fb
├───formatter
│   └───x86_64-linux: package 'nixpkgs-fmt-1.3.0'
└───packages
    └───x86_64-linux
        ├───bass: package 'sequence-of-145-notes.wav'
        ├───default: package 'garnix-music'
        ├───melody: package 'sequence-of-34-notes.wav'
        └───song: package 'overlay-of-180-notes.wav'

To avoid hiding information too much there could be a header saying something along the lines of:

Showing only outputs matching the current system (x86_64-linux).
Other systems are available: aarch64-darwin aarch64-linux x86_64-darwin
(use '--all-systems' to show all outputs)

This could also be exposed in a different way, like (only showing packages output):

github:garnix-io/sigbovik-music/ff983a1791fad30a6988f6451ac4f0726f30b2fb
└───packages
    └───x86_64-linux (+3 other systems, use `--all-systems` to show)
        ├───bass: package 'sequence-of-145-notes.wav'
        ├───default: package 'garnix-music'
        ├───melody: package 'sequence-of-34-notes.wav'
        └───song: package 'overlay-of-180-notes.wav'

Describe alternatives you've considered
Training my eyes to avoid seeing unwanted information... but I don't think it's a good idea... 👀

Priorities

Add 👍 to issues you find important.

@bew bew added the feature Feature request or proposal label Sep 20, 2023
@Atry
Copy link
Contributor

Atry commented Apr 6, 2024

Try grep!

$ nix flake show github:garnix-io/sigbovik-music | grep -v omitted
github:garnix-io/sigbovik-music/ff983a1791fad30a6988f6451ac4f0726f30b2fb
├───formatter
│   └───x86_64-linux: package 'nixpkgs-fmt-1.3.0'
└───packages
    ├───aarch64-darwin
    ├───aarch64-linux
    ├───x86_64-darwin
    └───x86_64-linux
        ├───bass: package 'sequence-of-145-notes.wav'
        ├───default: package 'garnix-music'
        ├───melody: package 'sequence-of-34-notes.wav'
        └───song: package 'overlay-of-180-notes.wav'

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature Feature request or proposal
Projects
None yet
Development

No branches or pull requests

2 participants