diff --git a/TODO.md b/TODO.md index cd150a3..077092e 100644 --- a/TODO.md +++ b/TODO.md @@ -16,9 +16,13 @@ - Should have sane defaults - Adding new arguments should be easy and obvious -- [ ] Add wrapper script to run main program (so that various assumptions related +- [x] Add wrapper script to run master program (so that various assumptions related to relative paths are safer) +- [ ] move `master-bin` into a subdir like `master/cmd` or whatever is + idiomatic for golang programs; adapt `master` wrapper shell script + accordingly + - [ ] Add unit tests all over the place. - ⚠️ Huge task - needs breakdown before starting diff --git a/master/.gitignore b/master/.gitignore index 1f7391f..824c87f 100644 --- a/master/.gitignore +++ b/master/.gitignore @@ -1 +1 @@ -master +master-bin diff --git a/master/go.mod b/master/go.mod index bcee3cf..b94b98f 100644 --- a/master/go.mod +++ b/master/go.mod @@ -1,4 +1,4 @@ -module philologue.net/diachron/master +module philologue.net/diachron/master-bin go 1.23.3 diff --git a/master/master b/master/master new file mode 100755 index 0000000..94b3e1a --- /dev/null +++ b/master/master @@ -0,0 +1,8 @@ +#!/bin/bash + +DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" + +cd "$DIR" + +./master-bin "$@" +