Skip to content

feat(ui): add "follow rename" to file commit history list - #34994

Merged
wxiaoguang merged 62 commits into
go-gitea:mainfrom
Chi-Iroh:main
Jun 3, 2026
Merged

wxiaoguang merged 62 commits into
go-gitea:mainfrom
Chi-Iroh:main

Conversation

@Chi-Iroh

@Chi-Iroh Chi-Iroh commented Jul 8, 2025

Copy link
Copy Markdown
Contributor

Fix #28253

@GiteaBot GiteaBot added the lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. label Jul 8, 2025
@wxiaoguang wxiaoguang added this to the 1.27.0 milestone Jun 3, 2026
@Chi-Iroh

Chi-Iroh commented Jun 3, 2026

Copy link
Copy Markdown
Contributor Author

Thank you very much @wxiaoguang !

@bircni

bircni commented Jun 3, 2026

Copy link
Copy Markdown
Member

Db test fail

@wxiaoguang wxiaoguang changed the title feat(ui): File history for renamed files, with '--follow' equivalent to show the complete history (v2) feat(ui): add "follow rename" to file commit history list for renamed files Jun 3, 2026
@wxiaoguang wxiaoguang changed the title feat(ui): add "follow rename" to file commit history list for renamed files feat(ui): add "follow rename" to file commit history list Jun 3, 2026
@wxiaoguang
wxiaoguang requested a review from Copilot June 3, 2026 11:34

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 12 out of 12 changed files in this pull request and generated 1 comment.

Comments suppressed due to low confidence (1)

routers/web/repo/commit.go:261

  • When commitsCount == -1 (unknown total / follow-rename mode), the paginator needs WithCurRows(...) to decide whether there is a next page. Without it, HasNext() is always false (curRows defaults to 0), so the “next” link never appears even when there are more results. You can also use the computed hasMore to avoid the paginator’s edge case where a full page on the last page would still show “next”.
	pager := context.NewPagination(commitsCount, setting.Git.CommitsRangeSize, page, 5)
	pager.AddParamFromRequest(ctx.Req)
	ctx.Data["Page"] = pager

Comment thread routers/web/repo/commit.go
wxiaoguang and others added 3 commits June 3, 2026 19:42
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Signed-off-by: wxiaoguang <wxiaoguang@gmail.com>
@GiteaBot GiteaBot added lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. and removed lgtm/need 1 This PR needs approval from one additional maintainer to be merged. labels Jun 3, 2026
@wxiaoguang
wxiaoguang enabled auto-merge (squash) June 3, 2026 17:23
@wxiaoguang
wxiaoguang disabled auto-merge June 3, 2026 17:23
@wxiaoguang
wxiaoguang enabled auto-merge (squash) June 3, 2026 17:23
@wxiaoguang
wxiaoguang disabled auto-merge June 3, 2026 17:24
@wxiaoguang
wxiaoguang enabled auto-merge (squash) June 3, 2026 17:24
@wxiaoguang
wxiaoguang merged commit b2748d7 into go-gitea:main Jun 3, 2026
25 checks passed
@Chi-Iroh

Chi-Iroh commented Jun 3, 2026

Copy link
Copy Markdown
Contributor Author

@Taldariner @fish0x00 Here it is :)

@wxiaoguang

Copy link
Copy Markdown
Contributor

Here it is :)

Yes! 1.27 nightly can be downloaded here:

zeekay pushed a commit to hanzoai/forge that referenced this pull request Jul 26, 2026
…4994)

Fix go-gitea#28253

---------

Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
wxiaoguang pushed a commit that referenced this pull request Aug 15, 2026
The dashboard activity feed was paginated with `[ui.user]
REPO_PAGING_NUM`
instead of `[ui] FEED_PAGING_NUM`.

The wrong setting was picked up when the page size was hoisted into a
local
variable in #34994, most likely
copied
from the `dashboardRepoList` block a few lines above. `REPO_PAGING_NUM`
should
only control repository lists.

Fixes #38925
bircni added a commit that referenced this pull request Aug 15, 2026
Backport #38935 by @bircni


The dashboard activity feed was paginated with `[ui.user]
REPO_PAGING_NUM`
instead of `[ui] FEED_PAGING_NUM`.

The wrong setting was picked up when the page size was hoisted into a
local
variable in #34994, most likely
copied
from the `dashboardRepoList` block a few lines above. `REPO_PAGING_NUM`
should
only control repository lists.

Fixes #38925

Co-authored-by: bircni <bircni@icloud.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. type/feature Completely new functionality. Can only be merged if feature freeze is not active.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

File history for renamed files, with '--follow' equivalent to show the complete history

10 participants