Developer Area/CLI Framework
From Mahara Wiki
< Developer Area
To facilitate creation of Command Line Interface (CLI) scripts, a CLI framework has been created for Mahara.
This is a work in progress
Features
The CLI framework has been designed to make creating CLI scripts easier. To this end, it has a number of features:
- help/usage creation supporting:
- descriptions;
- default values;
- example values; and
- word wrapping of text.
- option validation;
- log level control (ability to turn on verbosity); and an
- option getter supporting:
- long and short option names.
Usage
Basic usage is currently documented in htdocs/lib/cli.php