[checkmk-commits] Check_MK Git: check_mk: GIT handling: ignore untracked files

Mathias Kettner mk at mathias-kettner.de
Wed Sep 11 16:54:51 CEST 2013


Module: check_mk
Branch: master
Commit: fc36940d75e0013a644212065a74b6941cd91a75
URL:    http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=fc36940d75e0013a644212065a74b6941cd91a75

Author: Mathias Kettner <mk at mathias-kettner.de>
Date:   Wed Sep 11 16:54:48 2013 +0200

GIT handling: ignore untracked files

---

 web/htdocs/wato.py |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/web/htdocs/wato.py b/web/htdocs/wato.py
index 1780224..cbbd96f 100644
--- a/web/htdocs/wato.py
+++ b/web/htdocs/wato.py
@@ -397,10 +397,10 @@ def do_git_commit():
                 file(defaults.default_config_dir + "/" + subdir + "/.gitignore", "w").write("*\n!wato\n!wato/*\n")
 
         git_command(["add", ".gitignore", "*.d/wato"])
-        git_command(["commit", "--author", author, "-m", shell_quote(_("Initialized GIT for Check_MK"))])
+        git_command(["commit", "--untracked-files=no", "--author", author, "-m", shell_quote(_("Initialized GIT for Check_MK"))])
 
     # Only commit, if something is changed
-    if os.popen("cd '%s' && git status --porcelain" % defaults.default_config_dir).read().strip():
+    if os.popen("cd '%s' && git status --untracked-files=no --porcelain" % defaults.default_config_dir).read().strip():
         git_command(["add", "*.d/wato"])
         message = ", ".join(g_git_messages)
         if not message:



More information about the checkmk-commits mailing list