nushell / nushell.github.io

Nushell's main website, blog, book, and more
https://www.nushell.sh/book/
MIT License
162 stars 400 forks source link

Update docs for commands from `nu-std/std/dirs.nu` #1369

Closed isti115 closed 2 months ago

isti115 commented 2 months ago

Create an entry for dexit, which was missing, and add backlinks to the category page to the rest of the commands as well. (Closes https://github.com/nushell/nushell/issues/12642.)

fdncred commented 2 months ago

We don't allow editing of anything in the commands folder because those files are systematically generated with each new release. If we need changes to those commands the rust code or the std-lib code needs to change. Closing because of this. Thanks for trying to make our docs better. Please submit a PR on the nushell repo.

isti115 commented 2 months ago

Thanks for the feedback, @fdncred! As noted by my comment on the issue at the nushell repo (https://github.com/nushell/nushell/issues/12642#issuecomment-2075440609) as far as I could tell, these specific files are not part of the automatic generation process. :thinking:

They lack the <!-- This file is automatically generated. [...] --> notice, they have been left untouched for much longer (7 months) than everything else (3 weeks), their versions are stuck at 0.79.0 and (as opposed to the other commands, which are clearly documented by implementing the Command trait) I wasn't able to find their contents anywhere in the nushell repo, where they could potentially be generated from.

I think that even if the goal is to automatically generate the documentation of the standard library as well in the future, these changes are still valuable as they are right now, because the currently published version of the docs for these commands are clearly outdated. At least the entry for dexit should be added in my opinion.


P.S.: Also, the "Edit this page on GitHub" links of the template could be removed from the footers of command pages, or even better, somehow redirected to their implementations, but right now sadly I do not have available time to help with accomplishing that.


P.P.S.: Also, the header of the template needs to have its breakpoint adjusted. The content only fits properly above approximately 1000px of width, but the collapsed layout only activates below around 720px, which means that between those two values contents overlap and overflow. Aaargh, I should really create a separate issue... :upside_down_face: I'll try to sort these out when I'll have the capacity!

fdncred commented 2 months ago

@hustcer any ideas about these? Should we land these changes or are they systematically generated too?

hustcer commented 2 months ago

Yes,I think we can land this PR. It's true that we can't generate docs for std libs currently

isti115 commented 2 months ago

Thanks for reopening and merging @fdncred and @hustcer! In typical fashion, I noticed an error as soon as the PR got accepted, I've left the wrong frontmatter for dexit.md... :man_facepalming: Sorry for the mistake, I've sent a fixup in #1370!