Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The link to bypass .git-blame-ignore-revs in the blame view links to the wrong file #31429

Closed
noodlebox opened this issue Jun 19, 2024 · 2 comments · Fixed by #31432
Closed
Labels
topic/ui Change the appearance of the Gitea UI type/bug

Comments

@noodlebox
Copy link

Description

When revisions are hidden from the blame view, the URL for the link to bypass this feature appends ?bypass-blame-ignore=true to the path of .git-blame-ignore-revs ($revsFileLink again) instead of to that of the current file.

<p>{{ctx.Locale.Tr "repo.blame.ignore_revs" $revsFileLink (print $revsFileLink "?bypass-blame-ignore=true")}}</p>

blame.ignore_revs = Ignoring revisions in <a href="%s">.git-blame-ignore-revs</a>. Click <a href="%s">here to bypass</a> and see the normal blame view.

On the demo site: https://demo.gitea.com/noodlebox/test/blame/branch/main/README.md

Screenshots

image

Gitea Version

N/A

Can you reproduce the bug on the Gitea demo site?

Yes

Operating System

N/A

Browser Version

Any

@noodlebox noodlebox added topic/ui Change the appearance of the Gitea UI type/bug labels Jun 19, 2024
@wxiaoguang
Copy link
Contributor

I have an idea to fix it in 1.23 but it needs some new framework-level mechanism to handle URLs. 🤔

@wxiaoguang
Copy link
Contributor

Oops, it is a longstanding bug (maybe nobody ever used that link before), we can have a quick fix for it:

-> Fix the link for .git-blame-ignore-revs bypass #31432

@wxiaoguang wxiaoguang linked a pull request Jun 20, 2024 that will close this issue
wxiaoguang added a commit that referenced this issue Jun 20, 2024
GiteaBot pushed a commit to GiteaBot/gitea that referenced this issue Jun 20, 2024
@go-gitea go-gitea locked as resolved and limited conversation to collaborators Sep 18, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
topic/ui Change the appearance of the Gitea UI type/bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants