-
-
Notifications
You must be signed in to change notification settings - Fork 21.7k
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
Split generated RST for class reference based on the base type #63497
Conversation
2c5a49d
to
ad212b5
Compare
I like the idea generally, but I see a few issues:
|
It is, I kept it like that to avoid breaking all the links. Well, I guess the section itself can be called whatever... Objects, maybe? But I think from a casual user's perspective it's quite clear even with the current split.
No, internal identifiers for the classes are still the same and all the references should continue to work.
Yes, that is true. But this is for 4.0+, where a lot of old googled links break already due to renames, right? That said, if we change existing |
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.
We discussed this in a meeting, the feature makes sense.
We decided to try to keep the existing format for the URL to avoid the issue of having to know how a given class was categorized to guess its URL - several of us tend to go to the class reference for a given class by editing the URL manually in our browser. This might also be relied upon by external tools that want to link to the Godot docs programmatically.
To preserve this feature, we decided to have make_rst.py
generate the index.rst
with the subcategories instead of relying on prefixes.
ad212b5
to
f552d67
Compare
f552d67
to
4a5c179
Compare
Changes done, the Compared to the original version of this PR I've renamed "Classes" to "Objects", as it makes a bit more sense IMO. The rest should be functionally the same. Looks a little something like this: |
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.
It looks amazing! 🎉
Thanks! |
Sync with godotengine/godot#63497. From now on we also have to update `classes/index.rst` which is generated. I.e. the update procedure is: ``` cd godot/doc make rst cd ../../godot-docs rm -f classes/* cp ../../godot/doc/_build/rst/* classes/ ```
Related to godotengine/godot-proposals#4543.
Splits generated RSTs by using a different file prefix based on the base type of each class (node/resource/other), plus a dedicated group for global scopes (starting with
@
). This works in tandem with thegodot-docs
PR (godotengine/godot-docs#5990) to give this kind of grouping:chrome_2022-07-26_18-59-21.mp4