Skip to content

Commit

Permalink
modules_manager: ignore '.git' dir when load modules. (#1883)
Browse files Browse the repository at this point in the history
  • Loading branch information
k0ste authored and naparuba committed Sep 19, 2017
1 parent 0dfa784 commit 985d20a
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions shinken/modulesmanager.py
Expand Up @@ -152,6 +152,10 @@ def load(self):

del self.imported_modules[:]
for mod_name in modules_files:
# No look to .git folder
if mod_name == ".git":
logger.info("Found '.git' directory in modules, skip it.")
continue
mod_file = abspath(join(self.modules_path, mod_name, 'module.py'))
mod_dir = os.path.normpath(os.path.dirname(mod_file))
mod = self.try_load(mod_name, mod_dir)
Expand Down

0 comments on commit 985d20a

Please sign in to comment.