Crate gw_bin

source ·
Expand description

Watch local git repositories, keep in sync with remote and run commands.

§How it works

gw is built up from triggers, checks and actions. Triggers are long running background processes that initiates checks (for example periodic triggers, or HTTP triggers). Checks tests if there are any changes in the directory (be it git or filesystem changes) and runs the actions if there was. Actions are arbitrary code that runs (e.g. user-defined shell scripts).

+---------+       +--------+       +--------+
| trigger | ----> | checks | ----> | action |
+---------+       +--------+       +--------+

Modules§

  • An action is a process that runs if any changes occured (e.g. running scripts).
  • A check is a process that tests if there are any changes and updates it.
  • The main program loop, that runs the triggers, checks and actions infinitely.
  • A trigger is a long running background process, which initiates the checks (e.g. on a schedule, on HTTP request or once).