Mercurial > hg
comparison mercurial/hgweb.py @ 1767:adbc392dfd9e
implement entriesnotip for tags in hgweb.py ; change entries to entriesnotip in templates/tags-rss.tmpl
author | Peter van Dijk <peter@dataloss.nl> |
---|---|
date | Fri, 03 Feb 2006 02:21:28 +0100 |
parents | e8a3df8b62b3 |
children | 982fb022a16a |
comparison
equal
deleted
inserted
replaced
1766:93f54a2b3864 | 1767:adbc392dfd9e |
---|---|
652 mf = cl.read(cl.tip())[0] | 652 mf = cl.read(cl.tip())[0] |
653 | 653 |
654 i = self.repo.tagslist() | 654 i = self.repo.tagslist() |
655 i.reverse() | 655 i.reverse() |
656 | 656 |
657 def entries(**map): | 657 def entries(notip=False, **map): |
658 parity = 0 | 658 parity = 0 |
659 for k,n in i: | 659 for k,n in i: |
660 if notip and k == "tip": continue | |
660 yield {"parity": parity, | 661 yield {"parity": parity, |
661 "tag": k, | 662 "tag": k, |
662 "tagmanifest": hex(cl.read(n)[0]), | 663 "tagmanifest": hex(cl.read(n)[0]), |
663 "date": cl.read(n)[2], | 664 "date": cl.read(n)[2], |
664 "node": hex(n)} | 665 "node": hex(n)} |
665 parity = 1 - parity | 666 parity = 1 - parity |
666 | 667 |
667 yield self.t("tags", | 668 yield self.t("tags", |
668 manifest=hex(mf), | 669 manifest=hex(mf), |
669 entries=entries) | 670 entries=lambda **x: entries(False, **x), |
671 entriesnotip=lambda **x: entries(True, **x)) | |
670 | 672 |
671 def summary(self): | 673 def summary(self): |
672 cl = self.repo.changelog | 674 cl = self.repo.changelog |
673 mf = cl.read(cl.tip())[0] | 675 mf = cl.read(cl.tip())[0] |
674 | 676 |