Generate docs for generic peripherals

This was the easy bit. Now I've got to write them!
This commit is contained in:
SquidDev 2020-12-10 22:16:49 +00:00
parent bb8f4c624b
commit 05c3c8ad32
5 changed files with 23 additions and 2 deletions

View File

@ -123,7 +123,7 @@ accessTransformer file('src/main/resources/META-INF/accesstransformer.cfg')
deployerJars "org.apache.maven.wagon:wagon-ssh:3.0.0"
cctJavadoc 'cc.tweaked:cct-javadoc:1.2.1'
cctJavadoc 'cc.tweaked:cct-javadoc:1.3.0'
}
// Compile tasks
@ -346,6 +346,7 @@ task illuaminateDocs(type: Exec, dependsOn: [minifyWeb, luaJavadoc]) {
inputs.files(fileTree("doc")).withPropertyName("docs")
inputs.files(fileTree("src/main/resources/data/computercraft/lua/rom")).withPropertyName("lua rom")
inputs.file("illuaminate.sexp").withPropertyName("illuaminate.sexp")
inputs.dir("$buildDir/docs/luaJavadoc")
inputs.file("$buildDir/rollup/index.min.js").withPropertyName("scripts")
inputs.file("src/web/styles.css").withPropertyName("styles")
outputs.dir("$buildDir/docs/lua")

View File

@ -19,7 +19,8 @@
(source-link https://github.com/SquidDev-CC/CC-Tweaked/blob/${commit}/${path}#L${line})
(module-kinds
(peripheral Peripherals))
(peripheral Peripherals)
(generic_peripheral "Generic Peripherals"))
(library-path
/doc/stub/
@ -91,6 +92,10 @@
/build/docs/luaJavadoc/drive.lua
/build/docs/luaJavadoc/speaker.lua
/build/docs/luaJavadoc/printer.lua
; Generic peripherals
/build/docs/luaJavadoc/energy_storage.lua
/build/docs/luaJavadoc/fluid_storage.lua
/build/docs/luaJavadoc/inventory.lua
; Lua APIs
/src/main/resources/*/computercraft/lua/rom/apis/io.lua
/src/main/resources/*/computercraft/lua/rom/apis/window.lua)

View File

@ -15,6 +15,11 @@
import javax.annotation.Nonnull;
/**
* Methods for interacting with blocks using Forge's energy storage system.
*
* @cc.module energy_storage
*/
@AutoService( GenericSource.class )
public class EnergyMethods implements GenericSource
{

View File

@ -31,6 +31,11 @@
import static dan200.computercraft.shared.peripheral.generic.methods.ArgumentHelpers.getRegistryEntry;
/**
* Methods for interacting with tanks and other fluid storage blocks.
*
* @cc.module fluid_storage
*/
@AutoService( GenericSource.class )
public class FluidMethods implements GenericSource
{

View File

@ -32,6 +32,11 @@
import static dan200.computercraft.shared.peripheral.generic.methods.ArgumentHelpers.assertBetween;
/**
* Methods for interacting with inventories.
*
* @cc.module inventory
*/
@AutoService( GenericSource.class )
public class InventoryMethods implements GenericSource
{