You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When trying to use the documentation on Unit Script Template to create my own Unit Type, it seems to fail to use the code provided.
My definition:
module("my_compiler", package.seeall)
local nodegen = require "tundra.nodegen"
local _mt = nodegen.create_eval_subclass {}
local blueprint = {
Sources = {
Type = "source_list",
Help = "List of sources",
Required = true,
ExtensionKey = "MY_EXTENSION",
},
Name = {
Type = "string",
Required = true,
},
}
function _mt:create_dag(env, data, deps)
return env:make_node {
Label = "MyCompiler $(@)",
Action = "echo", --"$(MYACTION)",
Inputs = data.Sources,
Outputs = {},
Dependencies = deps,
}
end
nodegen.add_evaluator("MyCompiler", _mt, blueprint)
But when trying to run MyCompiler then I get that when trying to create the dag, it calls the :create_dag-function where the make_node function doesn't exist.
(attempt to call method 'make_node' (a nil value))
It would be really awesome if there would be an example of how to get this working in the examples/directory
The text was updated successfully, but these errors were encountered:
However, the notation of $(@) and $(<) seem undocumented (at least I can't find anything in the tundra-manual.html). When those are and aren't usable would be very good to document.
When trying to use the documentation on Unit Script Template to create my own Unit Type, it seems to fail to use the code provided.
My definition:
But when trying to run MyCompiler then I get that when trying to create the dag, it calls the :create_dag-function where the make_node function doesn't exist.
(attempt to call method 'make_node' (a nil value))
It would be really awesome if there would be an example of how to get this working in the examples/directory
The text was updated successfully, but these errors were encountered: