Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

A new task type for defining functions #51

Open
GoogleCodeExporter opened this issue Mar 28, 2015 · 0 comments
Open

A new task type for defining functions #51

GoogleCodeExporter opened this issue Mar 28, 2015 · 0 comments

Comments

@GoogleCodeExporter
Copy link

It would be nice to add a new type of task, that will allow to define functions 
(written in Java, Jython, JavaScript, AWK, etc. ) specified either directly 
within Hamake-file or as a reference to external file. Task will be defined by 
a tag '<function>', with two optional attributes: 'language=' and 'file', and 
one mandatory - 'id'. In case language is not specified, JavaScript will be 
used. 'file' attribute will be used to reference a file with script or program. 
 Unlike 'exec' task, 'function' task will have a direct read and write access 
to properties, defined globally for the Hamake-file. Also, one will be able to 
use functions for evaluation of expressions. Such tasks will allow to make 
Hamake-file less awkward and reduce its size by elimination need to use 
'<parameter>' tag to pass values of properties at a script. 'function' tasks 
will be useful for those, who want to add some complicated logic at the 
execution flow, e.g. run tasks only during specified time of a day, set a 
parameter according to some OS parameter, modify output of one task, before 
passing it as an input to other, e.t.c.  Vadim, Peter could you please comment 
this request for a new feature?  Vladimir

Original issue reported on code.google.com by [email protected] on 5 Aug 2011 at 9:13

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant