[diffoscope] 01/04: diffoscope.comparators: Add ability to override progress bar name on a per-File basis.
Chris Lamb
chris at chris-lamb.co.uk
Thu Dec 29 00:17:25 CET 2016
This is an automated email from the git hooks/post-receive script.
lamby pushed a commit to branch master
in repository diffoscope.
commit d6174c293e2e7a1190e42d9ca1a113eb28ebde20
Author: Chris Lamb <lamby at debian.org>
Date: Wed Dec 28 23:10:51 2016 +0000
diffoscope.comparators: Add ability to override progress bar name on a per-File basis.
---
diffoscope/comparators/utils/container.py | 2 +-
diffoscope/comparators/utils/file.py | 4 ++++
2 files changed, 5 insertions(+), 1 deletion(-)
diff --git a/diffoscope/comparators/utils/container.py b/diffoscope/comparators/utils/container.py
index 4768a60..c6c673e 100644
--- a/diffoscope/comparators/utils/container.py
+++ b/diffoscope/comparators/utils/container.py
@@ -95,7 +95,7 @@ class Container(object, metaclass=abc.ABCMeta):
my_member_name, my_member = my_members.popitem(last=False)
if my_member_name in other_members:
yield my_member, other_members.pop(my_member_name), NO_COMMENT
- p.step(msg=my_member.name)
+ p.step(msg=my_member.progress_name)
else:
my_reminders[my_member_name] = my_member
my_members = my_reminders
diff --git a/diffoscope/comparators/utils/file.py b/diffoscope/comparators/utils/file.py
index cceed47..7313698 100644
--- a/diffoscope/comparators/utils/file.py
+++ b/diffoscope/comparators/utils/file.py
@@ -108,6 +108,10 @@ class File(object, metaclass=abc.ABCMeta):
return self._as_container
@property
+ def progress_name(self):
+ return self._name
+
+ @property
def magic_file_type(self):
if not hasattr(self, '_magic_file_type'):
self._magic_file_type = File.guess_file_type(self.path)
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/reproducible/diffoscope.git
More information about the diffoscope
mailing list