From ec09469d1fc79afd0257a830ecdb3cf005cce4ef Mon Sep 17 00:00:00 2001 From: Ishaat Chowdhury Date: Mon, 6 Jan 2020 09:14:02 -0700 Subject: [PATCH 1/2] Update script usage in README --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index a7c63cd..6112306 100644 --- a/README.md +++ b/README.md @@ -65,7 +65,7 @@ Notes: * currently, folders are always watched recursively ## Usage -`gitwatch.sh [-r [-b ]]`
+`gitwatch.sh [-r [-b ]] `
It is expected that the watched file/directory are already in a git repository (the script will not create a repository). If a folder is being watched, this will be watched fully recursively; this also means that all files and sub-folders added and removed from the directory will always be added and removed in the next commit. The `.git` folder will be excluded from the `inotifywait` call so changes to it will not cause unnecessary triggering of the script. ### Starting on Boot From 2b125065f7220af4b4e54d3cb0b369767b085f1f Mon Sep 17 00:00:00 2001 From: Ishaat Chowdhury Date: Mon, 6 Jan 2020 09:15:30 -0700 Subject: [PATCH 2/2] Update systemd service --- gitwatch@.service | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gitwatch@.service b/gitwatch@.service index 6d22765..339ae7c 100644 --- a/gitwatch@.service +++ b/gitwatch@.service @@ -3,7 +3,7 @@ Description=Watch file or directory and git commit all changes. run with: system [Service] Environment="SCRIPT_ARGS=%I" -ExecStart=/usr/bin/gitwatch $SCRIPT_ARGS +ExecStart=/usr/local/bin/gitwatch $SCRIPT_ARGS ExecStop=/bin/true [Install]