Lua Doxygen

Find Tips and tricks on how to better use the Zeus editor. Feel free to post your own tips but please do not post bug reports, feature requests or questions here.
Site Admin
Posts: 2445
Joined: Fri Aug 13, 2004 5:10 pm

Lua Doxygen

Postby jussij » Wed Dec 21, 2016 11:38 pm

Here is a Node.js based Doxygen Lua filter:

To use this filter do the following:

1. Download and install Node.js found here:

2. Run the following Node.js command from the command prompt:

Code: Select all

npm install -g doxylua

This will create the following Node.js application:

Code: Select all

C:\Users\<Your User ID>\AppData\Roaming\npm\doxylua

NOTE: <Your User ID> will be your Windows user ID.

3. Start Zeus and make sure the doxylua application created earlier is in the PATH by running this Tools, DOS Command Line command:

Code: Select all


That command should produce this output:

Code: Select all

FILE argument is required

Usage: doxylua <FILE> [options]

FILE     The path to a lua file.

   -s, --show-ast    Print out the AST of the specified lua file.
   -l, --locations   Specify whether the location infos are included in the output.
                     Default to false.
                     Only has effect when --show-ast was set.

4. Create a new Zeus workspace containing all the Lua code to be documented.
workspace.png (143.61 KiB) Viewed 104 times

5. Use the Zeus Doxygen command to document the code contained in the workspace:
generate.png (22.1 KiB) Viewed 104 times

This step will create the following Doxygen configuration file:

Code: Select all

C:\Users\<Your User ID>\AppData\Roaming\Xidicone\Zeus\zOxygen\doxygen.dat

NOTE: <Your User ID> will be your Windows user ID.

6. Edit that file and add this line to that file:

Code: Select all

FILTER_PATTERNS = *.lua=doxylua

The change is made in the following location:
filter.png (39.81 KiB) Viewed 104 times

7. Re-run the Zeus Doxygen command and this time it will use the doxylua filter to document the Lua code as shown below:
help.png (219.42 KiB) Viewed 104 times

Cheers Jussi

Return to “Tutorials, Tips and Tricks”

Who is online

Users browsing this forum: No registered users and 1 guest