-
Notifications
You must be signed in to change notification settings - Fork 402
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
DOCS: TOC builder (for functions and providers) #2197
base: main
Are you sure you want to change the base?
Conversation
c642e49
to
4704075
Compare
OMG. So much structure. So many doc. Everything still appears intact on the doc builds. Could do with some polish for filenames. |
1c05618
to
5491262
Compare
I may invest some time to program a scour mechanism that goes through all markdown and updates all the links if a file has moved location or got renamed. But that can come later. |
That would work.
|
Thanks @systemcrash! Another step in the right direction! I myself have had similar ideas see #1998. I just don't know if I would make the same choice to generate the full Some examples: -CI/CD example for GitLab
+Ci-Cd-Gitlab -Why CNAME/MX/NS targets require a "dot"
+Why Targets Require The Final Dot I've always thought of two (or more) GitBook menu structures: I'm curious about your thoughts! @systemcrash @tlimoncelli |
8e269b5
to
0f106ec
Compare
OK - I'm satisfied with the results now.
Just a question of renaming the file (as closely) as possible. Or modifying the code to pick out the first
Do you think they're sufficiently mirrored in the current test results? Take a look and let me know @cafferata |
0f106ec
to
c6cceb5
Compare
In tandem with this PR, I recommend that (a few) providers might also be renamed (and their variables too?) to match the docs. Things like Route 53 are findable by search, although this one is actually called "Amazon Route 53". ( PR has overview of which provider md files got renamed ) |
a19f6de
to
6e85342
Compare
@systemcrash a number of feedback points:
|
9e15761
to
7eea9f1
Compare
Yes - thanks for the feedback. I made a few minor adjustments to retain the original structure as closely as possible. Seems to have worked nicely. The only part that won't align is the provider names - the provider .md files and the providers need renaming to synchronize or, another solution. When naming freely the provider md files, it looks like you want: If there is some structuring you don't like, one just has to rearrange the files/folders (bearing in mind to adjust any hyperlinks.) I think this is where we gain by "good code documents itself" - by renaming the providers so everything looks as you want it. |
b28b1fd
to
35f7f03
Compare
Hi @cafferata - are there any other changes you'd like to see for the long term?Or is it now just a question of modifying the processes on the docs server? |
a233784
to
df31642
Compare
I'm especially curious if @tlimoncelli agrees with the structure change.
|
I don't see the problem with technical details. If anything, it makes it easier for new-comers to find and contribute. I did not find a convenient way of forcing something to appear first, when everything is sorted alphanumerically, except perhaps naming entries What is the documentation trying to be? Reference? Howto? User guide (examples)? Reference should be alphabetically sorted (providers, functions). Howtos can land in a different folder and get a different TOC...? But we're trying to avoid all of this.
Do we need to? 'Everything else' in the project is sorted alphabetically, which makes it easier to locate entries (reference).
Such entries need to land outside of the tags, true. Other 'decorative' static entries can land somewhere in the middle, but that means more tags and more code complexity. I would rather code be easy to understand. 'Randomly' adding content goes into an existing file or makes a new file somewhere, which gets checked in anyway. Don't see the problem.
I made an earlier suggestion that we rename provider entries, to align with the real world. Only drawback is that users might have to (oh no) change a text string in their .js files. e.g.
So... how does one fix this, if gitbook is the solution? Relative but with some path depth?
The renames were made to follow how they are manually named in the TOC. Just rename the source file. 1:1 naming. Everything else was just link decoration. Now it's automatic. File == page == link.
This one I'm not sure how to resolve - I don't know what happens server side. ¯_(ツ)_/¯
Same content.
Documentation search precludes any of this from being a problem. Know what you want to find? ⌘K. |
My concern here is that if we add a section a lot of links will break. I would prefer a system where the name the user sees is not the directory name. This will also permit us to use characters that can't be in a directory name, such as Each file has a preamble (for example
That's also a problem. It is important that articles are listed in an order that improves usability/readability. For example, the more broad/introductory entries should be at the top of the list. (Fun fact: When you are at a restaurant for the first time and don't know what to order, the first 1-2 items in any section of the menu are the "safe" items that a new and non-adventurous eater should pick. Likewise, Apple's style-guide says that the items in a drop-down menu should be in the order a typical user will learn them. That's why Open comes before Save, and the last few items in the drop-down menu are the obscure features that most people won't use)
We only have 1 such link. No biggie. We could delete it or have a doc that tells people to go to the link.
This is fine. Though we probably want to shorten some of the full descriptions. |
Hi @systemcrash, your response feels personal. @tlimoncelli has asked me to provide feedback/view of this pull request. So I've listed the changes that aren't immediately obvious from the GitHub pull request description (or the big git diff). In addition, I explicitly asked how @tlimoncelli looks at these feedback points. Now it feels like we have to discuss each other's comments and that's not up to me. Would I personally have done it differently? Yes, I would have chosen to narrow the scope down to what you call 'reference' ( Am I grateful that you have taken up this work? Absolute! |
Better we find a long-term solution than just mashing this in there, since I understand that you put in some work server-side to make this work out. And yes, it's personal: it's my opinion based on this work. How about naming files with a number prefix for some kind of ordering, but the automation trims the number prefix away? The only other way I can think of is embedding the title you want in the first line(s) of the .md files (in certain folders) and using those. More complex, but it seems to strike a balance. just have to go through all files and ensure the first line always adheres to this standard. ( Similar to the preamble @tlimoncelli mentions, but not for alphabetically sorted reference stuff ) |
@systemcrash I appreciate all the effort you're putting into this. Good, readable, documentation is probably the most important way we bring new people into the project. I like all the ideas so far. Here are my thoughts about them:
Thoughts? Tom |
b4fd6bb
to
aa8b620
Compare
OK, updates:
As a result, all links work. TOC is auto-generated. Everybody is happy (I think). (I may have missed a link or two somewhere). renames/moves: We can increase scope/complexity of auto-generation later with these ideas if we are satisfied with how this currently works |
aa8b620
to
074c6e2
Compare
26d042e
to
46811d4
Compare
Shall we use this automation? |
(it has more error checks)
first attempt to automate TOC creation.
This is a draft so there's probably a few misses in here to sort through after some test doc generations.
Summary
Automatically generate the TOC in
SUMMARY.md
and fill it with the hierarchical doc structure found in the documentation folder. Now we don't need to manually update it or its links. Folder structure depth is mirrored in the TOC.It's possible to supply file/folder name exceptions at various points.
Checks are simple and can possibly be defeated.
Due to the (renames and) changes for this PR, it's not advisable to 'merge master' into this branch.... yet.