name = "example" version = "0.2.0" on_start = [{"plugin:logger" = { message = "Workflow '{{XTOMATE_WORKFLOW}}' started", level = "info", sub_app_name = "Status" }}] on_finish = ["notify_send", {"plugin:logger" = { message = "Workflow '{{XTOMATE_WORKFLOW}}' finished", level = "info", sub_app_name = "Status" }}, "clean"] [[plugins]] name = "notify_send" source = "https://github.com/vyPal/xtomate-plugin-notify-send" version = "^0.1.0" config = { app_name = "XTomate" } [[plugins]] name = "logger" source = "vyPal/xtomate-plugin-logger" version = "^0.1.0" config = { app_name = "XTomate", log_file = "xtomate.log" } [[templates]] name = "echo" command = "echo \"{{MESSAGE}}\" {{PIPE}}" [tasks.notify_send] run = false plugin = "notify_send" config = { message = "Workflow '{{XTOMATE_WORKFLOW}}' finished" } [tasks.clean] run = false command = "rm -rf testdir" dependencies = [{"prepdir" = "success"}] [tasks.willfail] command = "echo \"cs\" && exit 1" on_error = [{"plugin:logger" = { message = "Task '{{XTOMATE_TASK}}' failed: {{XTOMATE_STDOUT}}", level = "error", sub_app_name = "Tasks" }}] [tasks.prepdir] command = """ mkdir testdir cd testdir touch hello.py """ [tasks.createprogram] template = "echo" config = { MESSAGE = "print('hello world')", PIPE = "> testdir/hello.py" } dependencies = [{"prepdir" = "success"}] [tasks.writefile] template = "echo" config = { MESSAGE = "$WORLD $HELLO", PIPE = "> testdir/hello.txt" } dependencies = [{"prepdir" = "success"}] env = {HELLO = "world", WORLD = "hello"} [tasks.runprogram] command = "python testdir/hello.py && cat testdir/hello.txt" dependencies = [{"createprogram" = "success"}, {"writefile" = "success"}]