0
Fork 0
mirror of https://codeberg.org/forgejo/forgejo.git synced 2024-12-22 23:33:15 -05:00

Fix AGit checkout instruction

The checkout instruction for pull requests created with the AGit
workflow where incorrect.
This commit is contained in:
Beowulf 2024-07-13 18:05:08 +02:00
parent 28b81cd878
commit 0a5fa31edb
No known key found for this signature in database
GPG key ID: 44225F5F2792841D

View file

@ -9,10 +9,10 @@
<div class="ui secondary segment">
{{if eq .PullRequest.Flow 0}}
<div>git fetch -u {{if ne .PullRequest.HeadRepo.ID .PullRequest.BaseRepo.ID}}<origin-url data-url="{{.PullRequest.HeadRepo.Link}}"></origin-url>{{else}}origin{{end}} {{.PullRequest.HeadBranch}}:{{$localBranch}}</div>
<div>git checkout {{$localBranch}}</div>
{{else}}
<div>git fetch -u origin {{.GetGitRefName}}:{{$localBranch}}</div>
<div>git fetch -u origin +refs/pull/{{.PullRequest.Index}}/head:{{$localBranch}}</div>
{{end}}
<div>git checkout {{$localBranch}}</div>
</div>
{{if .ShowMergeInstructions}}
<div><h3>{{ctx.Locale.Tr "repo.pulls.cmd_instruction_merge_title"}}</h3>{{ctx.Locale.Tr "repo.pulls.cmd_instruction_merge_desc"}}</div>