top | item 42352071

(no title)

j6m8 | 1 year ago

I wrote frof [1] for exactly this purpose :)

Designed to be ultra-simple and with minimal "config-file acrobatics".

It looks like this [edit, formatting]:

    write -> analyze
    build -> analyze

    write:     echo 1 2 3 > data.txt
    build:     compile_tool.sh > tool.sh
    analyze:   tool.sh data.txt
https://github.com/j6k4m8/frof/

discuss

order

pdimitar|1 year ago

Can you explain that one a little bit more to me, please?

I don't get the first two lines of your example well. They seem to show the dependency but which one is the default task, or how do you ask for a task to be ran?

j6m8|1 year ago

You write the file and ALL steps are run in topological order so that a job never runs until its dependencies have run. i.e., in a tool I'll have `build.frof` as a separate frof file than `download-dependencies.frof`, perhaps. (If your preference is that those belong in the same file I'd be down to have PRs that support that! Should be very easy, I'm happy to try implementing this if there's interest.)

So for a file with those contents called `mygraph.frof`, you can (after installing) run `frof mygraph.frof` to kick off the jobs in the current shell (inheriting env vars etc).

[edit] maybe a clarifying example here: https://blog.jordan.matelsky.com/frof-render/