Code details

The code is namespaced ; main namespace name is g5.
Code is PSR-4 (namespace hierarchy corresponds to directory hierarchy, like in java).
Top-level namespace (g5) is located in src/.
Another top-level namespace is used (vendor), located in vendor/.
The code does not use composer or other dependency manager, vendor code is copied in vendor/ directory and versioned with the program.

All transformations on data are done in namespace g5\commands.

Association CLI - executed code

The command line interface (CLI) is handled by run-g5.php.
The code uses the parameters given to the CLI to find a class of namespace g5\commands implementing the Command interface.
For details about this mechanism, see comments of class g5\app\Run.

php run-g5.php ertel sport look date
triggers the execution of

One exception

This mechanism proved to be sufficient for most cases. It is convenient because it permits to add new commands which can be used directly without having to change a configuration, but couldn't fill the need to handle Gauquelin files of series A. For example, to have the ability to issue commands like
php run-g5.php gauq A1 tmp2db
php run-g5.php gauq A2 tmp2db
would impose namespace gauq to have a sub-namespace A1 and a sub-namespace A2 etc.

So if the first parameter is gauq, the association between the parameters given to the CLI and the command to execute is handled by g5\commands\gauq\GauqCommand.