From 4aa178022def247834f7ecfc45b5defbe9270d09 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Guido=20G=C3=BCnther?= Date: Sun, 20 Nov 2011 17:53:46 +0100 Subject: [PATCH] GitRepository: Return GitModifier from get_author_info --- examples/gbp-add-patch | 4 ++-- gbp/git/__init__.py | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/examples/gbp-add-patch b/examples/gbp-add-patch index 8a10eb5..059ac9c 100755 --- a/examples/gbp-add-patch +++ b/examples/gbp-add-patch @@ -94,8 +94,8 @@ def build_commit_msg(repo, patch, options): thanks = '' closes = '' - author, dummy = repo.get_author_info() - if author != patch.author_name(): + author = repo.get_author_info() + if author.name != patch.author_name(): thanks = "Thanks: %s" % patch.author_name() for line in patch.body.split('\n'): diff --git a/gbp/git/__init__.py b/gbp/git/__init__.py index 775da63..b1e419c 100644 --- a/gbp/git/__init__.py +++ b/gbp/git/__init__.py @@ -623,7 +623,7 @@ class GitRepository(object): config and environment variables. @return: name and email - @rtype: C{tuple} + @rtype: L{GitModifier} """ try: name = self.get_config("user.email") @@ -635,7 +635,7 @@ class GitRepository(object): email = os.getenv("EMAIL") email = os.getenv("GIT_AUTHOR_EMAIL", email) name = os.getenv("GIT_AUTHOR_NAME", name) - return (name, email) + return GitModifier(name, email) #{ Remote Repositories -- 2.7.4