Mercurial > public > mercurial-scm > hg-stable
comparison mercurial/hgweb/common.py @ 7310:bd522d09d5e3
hgweb: move the diffs() generator into webutil
author | Dirkjan Ochtman <dirkjan@ochtman.nl> |
---|---|
date | Mon, 03 Nov 2008 20:41:48 +0100 |
parents | 9c399c53469d |
children | a3d7f99c23c0 |
comparison
equal
deleted
inserted
replaced
7309:e74a9173c2d7 | 7310:bd522d09d5e3 |
---|---|
110 count += 1 | 110 count += 1 |
111 if stripecount and count >= stripecount: | 111 if stripecount and count >= stripecount: |
112 parity = 1 - parity | 112 parity = 1 - parity |
113 count = 0 | 113 count = 0 |
114 | 114 |
115 def countgen(start=0, step=1): | |
116 """count forever -- useful for line numbers""" | |
117 while True: | |
118 yield start | |
119 start += step | |
120 | |
121 def get_contact(config): | 115 def get_contact(config): |
122 """Return repo contact information or empty string. | 116 """Return repo contact information or empty string. |
123 | 117 |
124 web.contact is the primary source, but if that is not set, try | 118 web.contact is the primary source, but if that is not set, try |
125 ui.username or $EMAIL as a fallback to display something useful. | 119 ui.username or $EMAIL as a fallback to display something useful. |