(yet another) simple utility to rebuild/reload your Go program when source changes.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
juju2013 3a27f08237 kill process group, needed when TOURNETTE_RUNCMD spawm sub process, it's now linux (mac os?) dependen 1 year ago
.gitignore initial import 1 year ago
LICENSE add license, add README 1 year ago
README.md document TOURNETTE_INTERVAL 1 year ago
hamster.jpg add license, add README 1 year ago
main.go kill process group, needed when TOURNETTE_RUNCMD spawm sub process, it's now linux (mac os?) dependen 1 year ago

README.md

Tournette

Tournette: Gopher Wheel in Ancien French

hamster

This is (yet another) simple utility to rebuild/reload your Go program when source changes.

Features:

  • Simple, only one binary, no configuration file
  • Very simple, only one source file, change as you want
  • Flexible, not litmited to standard go commands

Installation:

go get github.com/juju2013/tournette

Simple usage:

cd your_project_path
tournette

This will compile your project by using go build . and then launch the result binary if successful.

Any change in your source will stop the current program, compile it and relaunch it again.

Advanced usage:

cd $HOME/projects/apolloXI/build
TOURNETTE_REGEX="^.*\.(go|py)$" \
TOURNETTE_BUILDCMD=./build.sh
TOURNETTE_RUNCMD=/ksc/SaturnV.sh \
TOURNETTE_DIR=$HOME/projects/apolloXI/src \
TOURNETTE_INTERVAL=1282 \
tournette \
-all -these options -go -to your_program

That means: any go or python source change in $HOME/projects/apolloXI/src will be detected within 1.282 seconds and will trigger $HOME/projects/apolloXI/build/build.sh to compile and then launch /ksc/SaturnV.sh with -all -these options -go -to your_program as arguments.

Copyright © 2019 by juju2013@github, under BSD license (see LICENSE file), image credit: Doenertier82