From dbae3295c4bf96313f673f01e2e1af8e3b632ba3 Mon Sep 17 00:00:00 2001 From: Christoph Trassl Date: Fri, 14 May 2010 00:51:24 +0200 Subject: [PATCH] Handle moved files correctly Moved files ('svn mv') where not handled properly. The move target would be correctly added to the taglist, the move source, however, wouldn't be removed from the taglist. Signed-off-by: Christoph Trassl Signed-off-by: Giel van Schijndel --- codetags/indexer.py | 5 +++-- 1 files changed, 3 insertions(+), 2 deletions(-) diff --git a/codetags/indexer.py b/codetags/indexer.py index cc56c1d..35cdcd2 100644 --- a/codetags/indexer.py +++ b/codetags/indexer.py @@ -7,7 +7,7 @@ import re import posixpath import cPickle as pickle from fnmatch import fnmatch -from trac.versioncontrol.api import Node +from trac.versioncontrol.api import Changeset, Node from trac.util.text import to_unicode try: @@ -157,7 +157,8 @@ class TagIndexer(object): folder = posixpath.dirname(path) if not self.is_path_valid(folder): continue - + if change == Changeset.MOVE: + changes.add(base_path) for rule in self.scan_files: if fnmatch(path, rule): changes.add(path) -- 1.7.2.5