diff options
author | Chris St. Pierre <chris.a.st.pierre@gmail.com> | 2012-04-20 11:41:05 -0400 |
---|---|---|
committer | Chris St. Pierre <chris.a.st.pierre@gmail.com> | 2012-05-04 11:10:39 -0400 |
commit | dcca31b923a65467f9f69a44025730eece634ac1 (patch) | |
tree | 1a48e1d8de94d82447c4cec4d94df86a3bd3b7b7 | |
parent | a8421cae0d2864e8bb9010656351f37d2db941c4 (diff) | |
download | bcfg2-dcca31b923a65467f9f69a44025730eece634ac1.tar.gz bcfg2-dcca31b923a65467f9f69a44025730eece634ac1.tar.bz2 bcfg2-dcca31b923a65467f9f69a44025730eece634ac1.zip |
made Deltas and Genshi lint plugins respect command-line filelist
-rw-r--r-- | src/lib/Bcfg2/Server/Lint/Deltas.py | 12 | ||||
-rwxr-xr-x | src/lib/Server/Lint/Genshi.py | 3 |
2 files changed, 8 insertions, 7 deletions
diff --git a/src/lib/Bcfg2/Server/Lint/Deltas.py b/src/lib/Bcfg2/Server/Lint/Deltas.py index 7627b0cb0..cf91d1d13 100644 --- a/src/lib/Bcfg2/Server/Lint/Deltas.py +++ b/src/lib/Bcfg2/Server/Lint/Deltas.py @@ -12,9 +12,9 @@ class Deltas(Bcfg2.Server.Lint.ServerPlugin): def check_entry(self, basename, entry): for fname in list(entry.entries.keys()): - match = entry.specific.delta_reg.match(fname) - if match: - self.LintError("%s-file-used" % match.group('delta'), - "%s file used on %s: %s" % (match.group('delta'), - basename, - fname)) + if self.HandlesFile(fname): + match = entry.specific.delta_reg.match(fname) + if match: + self.LintError("%s-file-used" % match.group('delta'), + "%s file used on %s: %s" % + (match.group('delta'), basename, fname)) diff --git a/src/lib/Server/Lint/Genshi.py b/src/lib/Server/Lint/Genshi.py index 552c495b2..56803246c 100755 --- a/src/lib/Server/Lint/Genshi.py +++ b/src/lib/Server/Lint/Genshi.py @@ -18,7 +18,8 @@ class Genshi(Bcfg2.Server.Lint.ServerPlugin): for eset in entries.values(): for fname, sdata in list(eset.entries.items()): - if fname.endswith(".genshi") or fname.endswith(".newtxt"): + if (self.HandlesFile(fname) and + (fname.endswith(".genshi") or fname.endswith(".newtxt"))): try: loader.load(sdata.name, cls=genshi.template.NewTextTemplate) |