unikent/moodle-local_adhoc — pull request #2 by skelty-unikent (2014-07-29 09:53:53+00:00)
Title: Add CLI script

So I can do this:

lrd-dev$ php55 /var/www/vhosts/kent.moodle/public/future/local/adhoc/cli/run_adhoc_task.php --list
== List of adhoc tasks (http://kent.moodle:8080/future) ==
ID Class Name
5 \local_rollover\task\backup
6 \local_rollover\task\backup

lrd-dev$ php55 /var/www/vhosts/kent.moodle/public/future/local/adhoc/cli/run_adhoc_task.php --execute=5
... used 0 dbqueries
... used 0.0098011493682861 seconds
Task failed: Can not find data record in database table rollovers.

lrd-dev$ php55 /var/www/vhosts/kent.moodle/public/future/local/adhoc/cli/run_adhoc_task.php --delete=5
Task '5' deleted.

lrd-dev$ php55 /var/www/vhosts/kent.moodle/public/future/local/adhoc/cli/run_adhoc_task.php --list
== List of adhoc tasks (http://kent.moodle:8080/future) ==
ID Class Name
6 \local_rollover\task\backup