Meshroom/meshroom/nodes/test/appendText.py
Yann Lanthony 16e8037fd7 [core] change Attributes declaration on Node description
Inputs and outputs Attributes are now declared in two separate lists
* no more isOutput field on Attribute description
* guarantee attributes order (was not the case in Python2 with class attributes)
* Attribute's name is now part of its description

Note: for now, input and output Attributes are still stored in a single model inside a Graph.
2017-10-31 19:47:32 +01:00

32 lines
741 B
Python

from meshroom.core import desc
class AppendText(desc.CommandLineNode):
commandLine = 'cat {inputValue} > {outputValue} && echo {inputTextValue} >> {outputValue}'
inputs = [
desc.File(
name='input',
label='Input File',
description='''''',
value='',
uid=[0],
),
desc.File(
name='inputText',
label='Input Text',
description='''''',
value='',
uid=[0],
)
]
outputs = [
desc.File(
name='output',
label='Output',
description='''''',
value='{cache}/{nodeType}/{uid0}/appendText.txt',
uid=[],
),
]