Proposal: quick compare buttons at branch list #2111

Closed
opened 2025-11-02 04:24:30 -06:00 by GiteaMirror · 2 comments
Owner

Originally created by @SagePtr on GitHub (Jul 29, 2018).

  • Gitea version (or commit ref): any
  • Git version: any
  • Operating system: any
  • Database: any
  • Can you reproduce the bug at https://try.gitea.io: no (server down)

Description

On /{user}/{repo}/branches page, there is brief list of branches.

Github shows compare button or pull request link for each non-default branch, which compares branch to default branch (usually master) and proposes to create Pull request (or links to pull request itself).

This functionality is missing in gitea. Would be good to implement this in gitea.

Screenshots

Originally created by @SagePtr on GitHub (Jul 29, 2018). - Gitea version (or commit ref): any - Git version: any - Operating system: any - Database: any - Can you reproduce the bug at https://try.gitea.io: no (server down) ## Description On /{user}/{repo}/branches page, there is brief list of branches. Github shows compare button or pull request link for each non-default branch, which compares branch to default branch (usually master) and proposes to create Pull request (or links to pull request itself). This functionality is missing in gitea. Would be good to implement this in gitea. ## Screenshots ![](https://habrastorage.org/webt/tq/bz/u6/tqbzu6fircwwfqo77ifpp1djllm.png)
GiteaMirror added the type/featuretype/proposal labels 2025-11-02 04:24:30 -06:00
Author
Owner

@SagePtr commented on GitHub (Jul 29, 2018):

To person who will edit template file (repos/branch/list.tmpl):
This part looks misaligned:

<td>
{{if .IsDeleted}}
	<s><a href="{{$.RepoLink}}/src/branch/{{.Name}}">{{.Name}}</a></s>
	<p class="time">{{$.i18n.Tr "repo.branch.deleted_by" .DeletedBranch.DeletedBy.Name}} {{TimeSinceUnix .DeletedBranch.DeletedUnix $.i18n.Lang}}</p>
{{else}}
	<a href="{{$.RepoLink}}/src/branch/{{.Name}}">{{.Name}}</a>
	<p class="time">{{$.i18n.Tr "org.repo_updated"}} {{TimeSince .Commit.Committer.When $.i18n.Lang}}</p>
</td>
{{end}}

</td> and {{end}} must swap places (not critical because closing </td> could be omited)

@SagePtr commented on GitHub (Jul 29, 2018): To person who will edit template file (repos/branch/list.tmpl): This part looks misaligned: ``` <td> {{if .IsDeleted}} <s><a href="{{$.RepoLink}}/src/branch/{{.Name}}">{{.Name}}</a></s> <p class="time">{{$.i18n.Tr "repo.branch.deleted_by" .DeletedBranch.DeletedBy.Name}} {{TimeSinceUnix .DeletedBranch.DeletedUnix $.i18n.Lang}}</p> {{else}} <a href="{{$.RepoLink}}/src/branch/{{.Name}}">{{.Name}}</a> <p class="time">{{$.i18n.Tr "org.repo_updated"}} {{TimeSince .Commit.Committer.When $.i18n.Lang}}</p> </td> {{end}} ``` `</td>` and `{{end}}` must swap places (not critical because closing `</td>` could be omited)
Author
Owner

@ghost commented on GitHub (Jul 31, 2018):

Related: #3683 #4567

@ghost commented on GitHub (Jul 31, 2018): Related: #3683 #4567
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#2111