=== modified file 'fiveaday/bzr.py' --- fiveaday/bzr.py 2008-06-20 09:10:41 +0000 +++ fiveaday/bzr.py 2008-06-20 14:21:44 +0000 @@ -99,11 +99,14 @@ # check if committed already in the last hour: if not force: - b = branch.Branch.open(files.local_branch()) - when_push = 10-(b.revno() % 10) - if when_push != 10: - print >> sys.stdout, _("Bugs have been added, but will be pushed in %d commits.") % when_push - return 0 # This is no error + b = branch.Branch.open(remote_branch()) + last_rev = b.last_revision() + if last_rev: + last_rev = b.repository.get_revision(last_rev) + seconds_since_last_commit = time.time() - last_rev.timestamp + if seconds_since_last_commit < 3600: + print >> sys.stdout, _("Bugs have been added, but not committed yet (already committed %d minutes ago).") % (seconds_since_last_commit/60) + return 0 # This is no error err = update_branch() if err: