pake
pake copied to clipboard
allow pakefile to add definition of custom parameters
Right now any custom parameter passed on the command line is rejected (ie. all the ones not defined in pakeapp class).
It would be nice if the user could add support for custom parameters, a la java (eg. -Dmyparam=myvalue), or by plain registration of more options.
As far as I can tell, this is now impossible, as the function run() does not allow to specify extra options definitions, but only options values. Also the do_option() method should be modified accordingly
PS: I just found out that optional arguments and options can be added on the cli after the name of the task. Duh. This allows me to reach my goals, but in a slightly more awkward way: for a generic parameter, I have to add its handling to all of my actions...
Tasks have arguments and named parameters (second and third parameters to run_XXXX functions).
On command-line they should be given after task name
07.04.2011, в 15:42, [email protected] написал(а):
Right now any custom parameter passed on the command line is rejected (ie. all the ones not defined in pakeapp class).
It would be nice if the user could add support for custom parameters, a la java (eg. -Dmyparam=myvalue), or by plain registration of more options.
As far as I can tell, this is now impossible, as the function run() does not allow to specify extra options definitions, but only options values. Also the do_option() method should be modified accordingly
Reply to this email directly or view it on GitHub: https://github.com/indeyets/pake/issues/12
"generic" arguments is an open question. so, I leave this bug opened