A Lab is a plain text file, with extension .ijt. Use any text editor to create the file, and test the file by running from a J session.
First ensure that the labs addon is installed, then load it and call lab_jlab_ with the lab filename. For example:
load 'labs/labs' NB. loads the labs addon lab_jlab_ '~mywork/mylab.ijt' NB. loads your lab
You can step through the lab in the usual way, for example press Ctrl-. in JHS or Ctrl-J in the Qt IDE. Equivalently, call lab_jlab_ as follows:
lab_jlab_ 0 NB. advance the lab
To test by chapter:
labjump_jlab_ N NB. moves to chapter N labjump_jlab_ '' NB. displays the chapter selection dialog
If the Lab has dependencies such as plot, then it is a good idea to test in a newly-installed system to ensure that LABDEPENDS is defined correctly, and that the Lab does indeed load the required dependencies.
A Lab will be installed in the J addons directory, see JAL. Files with extension *.ijt in this directory will be listed in the Lab selection dialogs, except for those specifically excluded, see below.
A Lab may be stored in a specific addon, e.g. ~addons/tables/tara/tara.ijt, or in the labs/labs addon itself, e.g. ~addons/labs/labs/core/monad.ijt.
To install, add the Lab file to the appropriate addon, update manifest.ijs and commit the SVN. The Lab will be available when the user updates the addon.
The file ~addons/labs/labs/exlabs.txt (see exlabs.txt) has lists of Labs that are excluded from lab selection dialogs, such as Labs that were designed for specific platforms.
For example, if the new Lab is intended only for the JHS IDE and will not run in the JQt IDE, then add the Lab to the JQt exclusion list, update the manifest and commit.