# HG changeset patch # User Mads Kiilerich # Date 1503890740 -7200 # Node ID ff5caafa26dc551a58e3c770ac811afe80cbbc62 # Parent 651e37ed51c641e7966695785496c69b3b1186dc vcs: let Git changesets return an empty set of bookmarks and drop vcs check before iterating bookmarks Git repositories already had an empty set of bookmarks. Do the same for Git changesets. diff -r 651e37ed51c6 -r ff5caafa26dc kallithea/controllers/feed.py --- a/kallithea/controllers/feed.py Thu Nov 03 20:03:03 2016 +0100 +++ b/kallithea/controllers/feed.py Mon Aug 28 05:25:40 2017 +0200 @@ -86,9 +86,8 @@ #branches, tags, bookmarks if cs.branch: desc_msg.append('branch: %s
' % cs.branch) - if h.is_hg(c.db_repo_scm_instance): - for book in cs.bookmarks: - desc_msg.append('bookmark: %s
' % book) + for book in cs.bookmarks: + desc_msg.append('bookmark: %s
' % book) for tag in cs.tags: desc_msg.append('tag: %s
' % tag) diff_processor, changes = self.__changes(cs) diff -r 651e37ed51c6 -r ff5caafa26dc kallithea/lib/vcs/backends/git/changeset.py --- a/kallithea/lib/vcs/backends/git/changeset.py Thu Nov 03 20:03:03 2016 +0100 +++ b/kallithea/lib/vcs/backends/git/changeset.py Mon Aug 28 05:25:40 2017 +0200 @@ -50,6 +50,10 @@ self._paths = {} @LazyProperty + def bookmarks(self): + return () + + @LazyProperty def message(self): return safe_unicode(self._commit.message) diff -r 651e37ed51c6 -r ff5caafa26dc kallithea/templates/changelog/changelog.html --- a/kallithea/templates/changelog/changelog.html Thu Nov 03 20:03:03 2016 +0100 +++ b/kallithea/templates/changelog/changelog.html Mon Aug 28 05:25:40 2017 +0200 @@ -152,13 +152,11 @@ ${cs.phase} %endif - %if h.is_hg(c.db_repo_scm_instance): - %for book in cs.bookmarks: - - ${h.link_to(book,h.url('changeset_home',repo_name=c.repo_name,revision=cs.raw_id))} - - %endfor - %endif + %for book in cs.bookmarks: + + ${h.link_to(book,h.url('changeset_home',repo_name=c.repo_name,revision=cs.raw_id))} + + %endfor %for tag in cs.tags: ${h.link_to(tag,h.url('changeset_home',repo_name=c.repo_name,revision=cs.raw_id))} diff -r 651e37ed51c6 -r ff5caafa26dc kallithea/templates/changelog/changelog_summary_data.html --- a/kallithea/templates/changelog/changelog_summary_data.html Thu Nov 03 20:03:03 2016 +0100 +++ b/kallithea/templates/changelog/changelog_summary_data.html Mon Aug 28 05:25:40 2017 +0200 @@ -48,13 +48,11 @@ ${h.person(cs.author)} - %if h.is_hg(c.db_repo_scm_instance): - %for book in cs.bookmarks: - - ${h.link_to(book,h.url('changeset_home',repo_name=c.repo_name,revision=cs.raw_id))} - - %endfor - %endif + %for book in cs.bookmarks: + + ${h.link_to(book,h.url('changeset_home',repo_name=c.repo_name,revision=cs.raw_id))} + + %endfor %for tag in cs.tags: ${h.link_to(tag,h.url('changeset_home',repo_name=c.repo_name,revision=cs.raw_id))} diff -r 651e37ed51c6 -r ff5caafa26dc kallithea/templates/changeset/changeset.html --- a/kallithea/templates/changeset/changeset.html Thu Nov 03 20:03:03 2016 +0100 +++ b/kallithea/templates/changeset/changeset.html Mon Aug 28 05:25:40 2017 +0200 @@ -73,13 +73,11 @@ ${_('Merge')} %endif - %if h.is_hg(c.db_repo_scm_instance): - %for book in c.changeset.bookmarks: - - ${h.link_to(book,h.url('changeset_home',repo_name=c.repo_name,revision=c.changeset.raw_id))} - - %endfor - %endif + %for book in c.changeset.bookmarks: + + ${h.link_to(book,h.url('changeset_home',repo_name=c.repo_name,revision=c.changeset.raw_id))} + + %endfor %for tag in c.changeset.tags: