Rev 36: merge bzr-email trunk in http://bazaar.launchpad.net/%7Evila/bzr/bzr-email
Vincent Ladeuil
v.ladeuil+lp at free.fr
Thu Sep 25 11:12:08 BST 2008
At http://bazaar.launchpad.net/%7Evila/bzr/bzr-email
------------------------------------------------------------
revno: 36
revision-id: v.ladeuil+lp at free.fr-20080925101200-ehcpe9wvyw599gte
parent: v.ladeuil+lp at free.fr-20080521083945-4mvpgin6wkfmwsxq
parent: jelmer at samba.org-20080805215127-f39s078p0837pku9
committer: Vincent Ladeuil <v.ladeuil+lp at free.fr>
branch nick: email
timestamp: Thu 2008-09-25 12:12:00 +0200
message:
merge bzr-email trunk
modified:
__init__.py __init__.py-20051018071212-f1765ec4521cab0b
emailer.py emailer.py-20070123220937-ec5y2n2oeoa0p4ue-1
------------------------------------------------------------
revno: 33.1.3
revision-id: jelmer at samba.org-20080805215127-f39s078p0837pku9
parent: jelmer at samba.org-20080805211227-exo2tn00vc61agd3
committer: Jelmer Vernooij <jelmer at samba.org>
branch nick: trunk
timestamp: Tue 2008-08-05 23:51:27 +0200
message:
Fix another typo pointed out by Elmo.
modified:
__init__.py __init__.py-20051018071212-f1765ec4521cab0b
------------------------------------------------------------
revno: 33.1.2
revision-id: jelmer at samba.org-20080805211227-exo2tn00vc61agd3
parent: john at arbash-meinel.com-20080605174057-dmtofft54dr4snri
committer: Jelmer Vernooij <jelmer at samba.org>
branch nick: trunk
timestamp: Tue 2008-08-05 23:12:27 +0200
message:
Fix typo: pricate -> private.
modified:
__init__.py __init__.py-20051018071212-f1765ec4521cab0b
------------------------------------------------------------
revno: 33.1.1
revision-id: john at arbash-meinel.com-20080605174057-dmtofft54dr4snri
parent: john at arbash-meinel.com-20080501225950-1qerrg9fp54ifmel
committer: John Arbash Meinel <john at arbash-meinel.com>
branch nick: email
timestamp: Thu 2008-06-05 12:40:57 -0500
message:
Special case showing a single revision without a merge.
This cuts out 2s of 'bzr commit' time for committing to a bzr.dev tree.
modified:
emailer.py emailer.py-20070123220937-ec5y2n2oeoa0p4ue-1
-------------- next part --------------
=== modified file '__init__.py'
--- a/__init__.py 2008-05-01 22:59:50 +0000
+++ b/__init__.py 2008-08-05 21:51:27 +0000
@@ -37,7 +37,7 @@
- The URL of the branch itself.
Setting public_branch is highly recommended if you commit via a protocol which
-has a pricate address (e.g. bzr+ssh but anonymous access might be bzr:// or
+has a private address (e.g. bzr+ssh but anonymous access might be bzr:// or
http://).
How emails are sent is determined by the value of the configuration option
@@ -46,7 +46,7 @@
- ``smtplib``: Use python's smtplib to send the mail. If you use 'smtplib' you
can also configure the settings "smtp_server=host[:port]",
"smtp_username=userid", "smtp_password". If "smtp_username" is set but
- "smtp_password" is not, you will be prompted for a password.S
+ "smtp_password" is not, you will be prompted for a password.
Also, if using 'smtplib', the messages will be sent as a UTF-8 text message,
with a 8-bit text diff attached (rather than all-as-one). Work has also been
=== modified file 'emailer.py'
--- a/emailer.py 2008-05-21 08:39:45 +0000
+++ b/emailer.py 2008-09-25 10:12:00 +0000
@@ -46,7 +46,7 @@
self.revno = self.branch.revision_id_to_revno(self._revision_id)
def body(self):
- from bzrlib.log import log_formatter, show_log
+ from bzrlib import log
rev1 = rev2 = self.revno
if rev1 == 0:
@@ -63,17 +63,25 @@
outf.write('At %s\n\n' % self.url())
- lf = log_formatter('long',
- show_ids=True,
- to_file=outf
- )
+ lf = log.log_formatter('long',
+ show_ids=True,
+ to_file=outf
+ )
- show_log(self.branch,
- lf,
- start_revision=rev1,
- end_revision=rev2,
- verbose=True
- )
+ if len(self.revision.parent_ids) <= 1:
+ # This is not a merge, so we can special case the display of one
+ # revision, and not have to encur the show_log overhead.
+ lr = log.LogRevision(self.revision, self.revno, 0, None)
+ lf.log_revision(lr)
+ else:
+ # let the show_log code figure out what revisions need to be
+ # displayed, as this is a merge
+ log.show_log(self.branch,
+ lf,
+ start_revision=rev1,
+ end_revision=rev2,
+ verbose=True
+ )
return outf.getvalue()
More information about the bazaar-commits
mailing list