diff options
author | Peter Wu <peter@lekensteyn.nl> | 2015-03-24 17:57:38 +0100 |
---|---|---|
committer | Peter Wu <peter@lekensteyn.nl> | 2015-03-24 17:57:38 +0100 |
commit | 715c77a2e03d267f6697909b7943374c4d0e107f (patch) | |
tree | c790d0c1fc714e9664d29f4ec413c73668d45f8a /sync-build.sh | |
parent | b0e2a24647e8ecfc2be9344a98895521a385a3c0 (diff) | |
download | wireshark-notes-715c77a2e03d267f6697909b7943374c4d0e107f.tar.gz |
sync-build.sh: immediatelly trigger build on exec
Avoids the need to manually touch /tmp/sync-build-* to trigger a build
on startup. Can be overridden with the NOTRIGGER=1 env.
Diffstat (limited to 'sync-build.sh')
-rwxr-xr-x | sync-build.sh | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/sync-build.sh b/sync-build.sh index 0291be1..afcb2e2 100755 --- a/sync-build.sh +++ b/sync-build.sh @@ -23,6 +23,7 @@ # * NOCOPY=1 - do not sync the generated binaries back # * B32=1 - build 32-bit (using /usr/lib32) # * force_cmake - Set to non-empty to run cmake before make. +# * NOTRIGGER=1 - Do not immediately start building on execution # LOCAL source dir (on non-volatile storage for reliability) localsrcdir=$HOME/projects/wireshark/ @@ -149,6 +150,10 @@ fi monitor_changes & monpid=$! +if [ -z "${NOTRIGGER:-}" ]; then + sleep .5 && touch "$sync" & +fi + echo Waiting... while inotifywait -qq -e close_write "$sync"; do echo Woke up... |