Skip to content

Documented all lua binds directly in the source

Thorbjørn Lindeijer requested to merge Ablu:autodocs into master

This change adds a comment to each lua binding. In the future a script should parse those and generate the docs from them.

This should prevent outdated docs and duplicate effort to keep code and docs synced.

In C++ categories can be defined in this way:

/** LUA_CATEGORY long description of the category (shortname)
 * further text
 * goes into
 * the next lines
 */

The shortname is only used to bind other comments to the category.

In lua the category would look like this:

--- LUA_CATEGORY long description of the category (shortname)
-- further text
-- goes into
-- the next lines

A comment that describes a bind then can look like this:

/** LUA some_function (shortnameofcategory)
 * some_function(string name)
 * some_function(int id)
 **
 * Description
 */

Or in Lua:

--- LUA some_function (shortnameofcategory)
-- some_function(string name)
-- some_function(int id)

---
-- Description

Autoupdates script follows soon

Merge request reports