From 89b7a1411e4658e831f5d635534b24355dbb941d Mon Sep 17 00:00:00 2001 From: "W. Trevor King" Date: Tue, 15 Dec 2009 06:44:20 -0500 Subject: Fixed libbe.command.diff + ugly BugDir.duplicate_bugdir implementation duplicate_bugdir() works, but for the vcs backends, it could require shelling out for _every_ file read. This could, and probably will, be horribly slow. Still it works ;). I'm not sure what a better implementation would be. The old implementation checked out the entire earlier state into a temporary directory pros: single shell out, simple upgrade implementation cons: wouldn't work well for HTTP backens I think a good solution would run along the lines of the currently commented out code in duplicate_bugdir(), where a VersionedStorage.changed_since(revision) call would give you a list of changed files. diff could work off of that directly, without the need to generate a whole duplicate bugdir. I'm stuck on how to handle upgrades though... Also removed trailing whitespace from all python files. --- libbe/util/plugin.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'libbe/util/plugin.py') diff --git a/libbe/util/plugin.py b/libbe/util/plugin.py index 982c5ca..0326cda 100644 --- a/libbe/util/plugin.py +++ b/libbe/util/plugin.py @@ -57,7 +57,7 @@ def modnames(prefix): >>> 'plugin' in [n for n in modnames('libbe.util')] True """ - components = prefix.split('.') + components = prefix.split('.') modfiles = os.listdir(os.path.join(_PLUGIN_PATH, *components)) modfiles.sort() for modfile in modfiles: -- cgit