aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAdam Mathes <adam@trenchant.org>2018-02-18 09:59:00 -0800
committerAdam Mathes <adam@trenchant.org>2018-02-18 09:59:00 -0800
commit8d39f2652cf8c511b039d8d6cc73ceff135a2d99 (patch)
treefff8b75b7c6beeab28950dfae0495d5cd5b46948
parent9989337b3f760267f40bfe67a501eed3de012417 (diff)
downloadsnkt-8d39f2652cf8c511b039d8d6cc73ceff135a2d99.tar.gz
snkt-8d39f2652cf8c511b039d8d6cc73ceff135a2d99.tar.bz2
snkt-8d39f2652cf8c511b039d8d6cc73ceff135a2d99.zip
watch for all events except chmod and rebuild to handle file creation/rename/deletionv0.1
-rw-r--r--main.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/main.go b/main.go
index c938916..3cb6f57 100644
--- a/main.go
+++ b/main.go
@@ -93,7 +93,7 @@ func watchSite() {
for {
select {
case event := <-watcher.Events:
- if event.Op&fsnotify.Write == fsnotify.Write {
+ if event.Op&fsnotify.Write != fsnotify.Chmod {
fmt.Printf("rebuilding... ")
buildSite()
fmt.Printf("done\n")