summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJon Bergli Heier <snakebite@jvnv.net>2011-02-03 21:07:07 +0100
committerJon Bergli Heier <snakebite@jvnv.net>2011-02-03 21:07:07 +0100
commit4c171bf0e82c15437317cebda4008aacd944c36e (patch)
tree3e1707913a267adedf72ba928dbf3a149c14aa25
parent000c5eb8fb13049922bebbb1e116d58b7f739928 (diff)
Ignore files in root directory.
-rwxr-xr-xgitnoti.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/gitnoti.py b/gitnoti.py
index dfd79c3..5d5f186 100755
--- a/gitnoti.py
+++ b/gitnoti.py
@@ -185,7 +185,9 @@ class ReposNotifyEvent(pyinotify.ProcessEvent):
def process_IN_CREATE(self, event):
if os.path.dirname(event.pathname) == root:
- self.new_repo(event)
+ # Ignore files in root directory
+ if os.path.isdir(event.pathname):
+ self.new_repo(event)
else:
self.updated_repo(event)