From 406bd73a44f490cc671bbc0bdda6960aa124bf4e Mon Sep 17 00:00:00 2001 From: Ben Kurtovic Date: Sat, 30 Apr 2011 23:07:34 -0400 Subject: [PATCH] make status one msg instead of two --- irc/commands/git.py | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/irc/commands/git.py b/irc/commands/git.py index 3b00cda..344c1ec 100644 --- a/irc/commands/git.py +++ b/irc/commands/git.py @@ -153,9 +153,8 @@ class Git(BaseCommand): def do_status(self): """check whether we have anything to pull""" last = self.exec_shell("git log -n 1 --pretty=\"%ar\"") - self.connection.reply(self.data, "last commit was %s. Checking remote for updates..." % last) result = self.exec_shell("git fetch --dry-run") - if not result: - self.connection.reply(self.data, "local copy is up-to-date with remote.") + if not result: # nothing was fetched, so remote and local are equal + self.connection.reply(self.data, "last commit was %s. Local copy is \x02up-to-date\x0F with remote." % last) else: - self.connection.reply(self.data, "remote is ahead of local copy.") + self.connection.reply(self.data, "last local commit was %s. Remote is \x02ahead\x0F of local copy." % last)