From d21380b1f0beafe83efeabd2c48a76274c0200d9 Mon Sep 17 00:00:00 2001 From: Holger Schurig Date: Fri, 26 Jun 2009 00:14:08 +0200 Subject: [PATCH] webber: allow relative paths in cfg.exclude_files --- webber.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/webber.py b/webber.py index 194ce5c..29b4069 100644 --- a/webber.py +++ b/webber.py @@ -519,6 +519,13 @@ def walk_tree(dirpath): if ok: #print "FILE", s rel_path = relpath(cfg.in_dir, full_path) + # Allow paths to be specified in exclude_files: + for e in cfg.exclude_files: + if fnmatch.fnmatch(rel_path, e): + log("ignoring file %s" % rel_path, level=7) + ok = False + break + if ok: log("reading file %s" % rel_path, level=5) file = File( path = full_path, -- 2.39.2