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

Integrated Documentation #97

Merged
merged 84 commits into from
Feb 17, 2024
Merged

Conversation

WaitingIdly
Copy link
Collaborator

@WaitingIdly WaitingIdly commented Nov 25, 2023

Changes in this PR:

  • Adds documentation annotations to the API folder, with fairly sizable javadocs.
  • Documented Mods: Actually Additions, Advanced Mortars, Applied Energistics 2, Astral Sorcery, Avaritia, Blood Magic: Alchemical Wizardry, Botania, Chisel, Compact Machines 3, Draconic Evolution, EnderIO, EvilCraft, Extended Crafting, Immersive Engineering, Inspirations, Integrated Dynamics, Mekanism, Roots, Thaumcraft, Woot. View changes over at Document most mods and adjust some styling GroovyScript-Docs#18.
    • Mods with compat in GroovyScript that are not documented via this mechanism: Forestry, GregTech, JEI, Thermal Expansion, Tinkers' Construct, Tinkers Complement, Industrial Craft 2.
  • Adds methods to process the annotations and generate markdown files for the mkdocs-material wiki.
  • Adds methods to process the annotations and generate example files.
  • Adds a pair of commands for a player in-game to generate the wiki and examples files.
  • Make wrapEnum work properly respective to the caseSensitive param.
  • Make modcontainer aliases include the mod name.
  • Make Thaumcraft's ArcaneWorkbench, Aspect, and Research classes into registries.
  • Change a few methods in Thaumcraft compat (add streamRecipes, removeAll).
  • Increase the aliases generated for a few registries.
  • Add a way for mods to generate source links to the source code of their mod.

Add documentation to...

... new compat in GroovyScript:

  • Add annotations (@RegistryDescription, @MethodDescription, @RecipeBuilderDescription, @Property, @RecipeBuilderMethodDescription, and @RecipeBuilderRegistrationMethod) to the respective class, methods, and fields.
  • Add localization keys to en_us.lang
  • Launch the game with the mod enabled. documentation will then be generated.

... a separate mod:

  • Include the src/main/java/com/cleanroommc/groovyscript/api/ to access the annotations
  • Make a new implementation of ILinkGenerator and register it via LinkGeneratorHooks.registerLinkGenerator during onConstruction and have @RegistryDescription(linkGenerator = your impl). This will generate a link to your source code that is accessible on any wiki pages for that registry.
  • Follow the rest of the steps listed above in new compat in GroovyScript

@IntegerLimit
Copy link
Contributor

Like this idea a lot.

@WaitingIdly WaitingIdly linked an issue Nov 29, 2023 that may be closed by this pull request
# Conflicts:
#	src/main/java/com/cleanroommc/groovyscript/GroovyScript.java
#	src/main/java/com/cleanroommc/groovyscript/compat/mods/astralsorcery/perktree/PerkTreeConfig.java
#	src/main/resources/assets/groovyscript/lang/en_us.lang
Copy link
Member

@brachy84 brachy84 left a comment

Choose a reason for hiding this comment

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

Only reviewed the generation part and even that only a little bit. I trust you on the other stuff.

@brachy84 brachy84 merged commit bc60f40 into CleanroomMC:master Feb 17, 2024
@WaitingIdly WaitingIdly deleted the documentation branch March 16, 2024 08:21
@WaitingIdly WaitingIdly restored the documentation branch March 16, 2024 08:21
@WaitingIdly WaitingIdly deleted the documentation branch March 16, 2024 08:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

crash on startup with botania on 0.7.0
3 participants