name = "example"
version = "0.1.0"
on_start = ["log_start"]
on_finish = ["notify_send", "log_done"]
[[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 = "https://github.com/vyPal/xtomate-plugin-logger"
version = "^0.1.0"
config = { app_name = "XTomate", log_file = "xtomate.log" }
[tasks.notify_send]
run = false
plugin = "notify_send"
config = { message = "Workflow finished" }
[tasks.log_done]
run = false
plugin = "logger"
config = { message = "Workflow finished", level = "info", sub_app_name = "Status" }
[tasks.log_start]
run = false
plugin = "logger"
config = { message = "Workflow started", level = "info", sub_app_name = "Status" }
[tasks.prepdir]
command = """
mkdir testdir
cd testdir
touch hello.py
"""
[tasks.createprogram]
command = '''
echo "print('hello world')" > testdir/hello.py
'''
dependencies = [{"prepdir" = "success"}]
[tasks.writefile]
command = '''
echo "$WORLD $HELLO" > 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"}]