We use the YAML data-serialization language to configure jobs in Runlet. The job syntax block is fairly simple and you can define a job in two ways:
myjob: ls -lah
myjob:script: ls -lah
You can define jobs with a long multi-line string as follows:
myjob:script: |ls -lahecho "Job has finished"myjob2: |ls -lahecho "Job 2 has finished"
You can define a description for a job that will be shown in the desktop app.
myjob:script: "ls -lah"description: "This job shows all the content of the current folder"
myjob:script: ls -lahcwd: "/home/user/.config"
By default jobs are executed using
/bin/bash on Linux and MacOS and
cmd.exe on Windows. You can change this behavior by using the
myjob:script: |import timefor i in range(3600):print(i)time.sleep(1)entrypoint: [ "python" ]
It requires a list of strings denoting the binary to be used and a list of args. Runlet will wrap the contents of
script in a file and pass to the entrypoint execute.