Skip to content

Document each store type on its own page#9504

Merged
fricklerhandwerk merged 1 commit intoNixOS:masterfrom
fricklerhandwerk:store-implementation-per-page
Dec 1, 2023
Merged

Document each store type on its own page#9504
fricklerhandwerk merged 1 commit intoNixOS:masterfrom
fricklerhandwerk:store-implementation-per-page

Conversation

@fricklerhandwerk
Copy link
Contributor

@fricklerhandwerk fricklerhandwerk commented Nov 30, 2023

@Ericson2314 Review and rework of #8781

Motivation

This makes for more useful manual table of contents, that displays the
information at a glance.

Context

This change also lists all store types at the top of the respective overview page.

The nix help-stores command is kept as-is, even though it will show up
in the manual with the same information as these pages due to the way it
is written as a "--help-style" command. Deciding what to do with that
command is left for a later PR.

This work is sponsored by Antithesis

Priorities

Add 👍 to pull requests you find important.

@github-actions github-actions bot added documentation new-cli Relating to the "nix" command store Issues and pull requests concerning the Nix store labels Nov 30, 2023
# FIXME: this is a horrible hack to keep `nix help-stores` working.
# the correct answer to this is to remove that command and replace it
# by statically generated manpages or the output of something like `nix
# store info <store type>`.
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
# store info <store type>`.
# store docs <store type>`.

I'd say info is for dumping info about instances of the noun rather than docs about the concept (or subtypes).

Copy link
Member

Choose a reason for hiding this comment

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

I think that's an intentional difference :)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yeah, these are just ramblings.

filename = "${slug}.md";
page = showStore { inherit name slug; } storeInfo.${name};
})
(attrNames storeInfo);
Copy link
Member

Choose a reason for hiding this comment

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

off-topic: We could get ourselves a lib after implementing subtree fetching.

Copy link
Member

@Ericson2314 Ericson2314 left a comment

Choose a reason for hiding this comment

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

From my phone, looks good modulo "slug" shadowing @roberth found.

@fricklerhandwerk fricklerhandwerk force-pushed the store-implementation-per-page branch from 829d3f5 to e25cffe Compare November 30, 2023 23:52
This makes for more useful manual table of contents, that displays the
information at a glance.

The `nix help-stores` command is kept as-is, even though it will show up
in the manual with the same information as these pages due to the way it
is written as a "`--help`-style" command. Deciding what to do with that
command is left for a later PR.

This change also lists all store types at the top of the respective overview page.

Co-authored-by: John Ericson <John.Ericson@Obsidian.Systems
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation new-cli Relating to the "nix" command store Issues and pull requests concerning the Nix store

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants