Otto
86496d701d
Merge pull request '[v9.0/forgejo] fix: handle renamed dependency for cargo registry' ( #5945 ) from bp-v9.0/forgejo-bb93d3e into v9.0/forgejo
...
Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/5945
Reviewed-by: Gusted <gusted@noreply.codeberg.org>
2024-11-13 23:13:42 +00:00
Gusted
de389f2ecc
fix: handle renamed dependency for cargo registery
...
- When a dependency is renamed, specified via `package="actual-name"` in
Cargo.toml, this should become the name of the depedency when the
package is retrieved from the registery by cargo and the old name should
be available in the `package` field.
- The reference implementation also does this: 490e66a9d6/src/controllers/krate/publish.rs (L702-L705)
- Resolves #5936
- Unit test added.
(cherry picked from commit bb93d3e6c8
)
2024-11-13 22:56:30 +00:00
Earl Warren
e43533cd1b
Merge pull request '[v9.0/forgejo] chore(release): also copy the release to code.forgejo.org' ( #5937 ) from bp-v9.0/forgejo-7492330 into v9.0/forgejo
...
Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/5937
Reviewed-by: Earl Warren <earl-warren@noreply.codeberg.org>
2024-11-13 18:33:57 +00:00
Earl Warren
2a78dba95b
chore(ci): trigger a mirror when a release is publish
...
Notify https://code.forgejo.org/forgejo/forgejo that a new release was
published by setting the trigger label to
https://code.forgejo.org/forgejo/forgejo/issues/5 .
It is only ever useful when a stable release is published, the
experimental releases are not mirrored. But it is triggered in all
cases. This will waste a few mirror check daily, when experimental
releases are built. This is an improvement compared to the current
situation where mirrors are checked hourly:
* Instead of being checked 24 times per day it will be down to less
than 5
* The mirror happens immediately after the release is published
instead of waiting for the next run of the cron job.
If a mirror operation is in progress, as evidenced by the presence of
the trigger label on the issure, it means two releases are being
published. Wait up to 1h for the mirror to complete and remove the
trigger label.
(cherry picked from commit 7492330721
)
2024-11-13 16:53:43 +00:00
Earl Warren
e9cd753b98
Merge pull request '[v9.0/forgejo] fix(ci): synchronize updates the commit status asynchronously' ( #5926 ) from bp-v9.0/forgejo-983aed4 into v9.0/forgejo
...
Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/5926
Reviewed-by: Earl Warren <earl-warren@noreply.codeberg.org>
2024-11-12 12:33:20 +00:00
Earl Warren
dac13b7fc3
fix(ci): synchronize updates the commit status asynchronously
...
When a new commit is pushed to an existing pull request, the update of
the commit status will happen asynchronously, via the git hook.
--- FAIL: TestPullRequestCommitStatus/synchronize (2.14s)
actions_trigger_test.go:331:
Error Trace: /workspace/forgejo/forgejo/tests/integration/actions_trigger_test.go:331
Error: Should be true
Test: TestPullRequestCommitStatus/synchronize
(cherry picked from commit 983aed4268
)
2024-11-12 11:53:06 +00:00
Otto
0db515dfec
Merge pull request '[v9.0/forgejo] fix: Move forgot_password-link to fix login tab order' ( #5887 ) from fnetx/bp-5838 into v9.0/forgejo
...
Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/5887
Reviewed-by: Gusted <gusted@noreply.codeberg.org>
2024-11-10 13:41:51 +00:00
Gusted
336ccf45c8
Merge pull request '[v9.0/forgejo] fix(ui): Details icon in repo settings sidebar' ( #5891 ) from bp-v9.0/forgejo-5932b86 into v9.0/forgejo
...
Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/5891
Reviewed-by: Otto <otto@codeberg.org>
Reviewed-by: Gusted <gusted@noreply.codeberg.org>
2024-11-10 12:54:50 +00:00
Otto Richter
70aefc810c
fix(ui): Details icon in repo settings sidebar
...
Consistent classes between both details/summary constructs in the sidebar, ensuring they have the same style.
(cherry picked from commit 5932b86af4
)
2024-11-10 02:13:45 +00:00
MrSmoer
6025b93664
Remove unused css class "form-field-content-aside-label"
...
This css class was used to display the "forgot password"-link right and above the password field.
cd75519a0b
moves this link, so this class is now unused
2024-11-10 02:24:58 +01:00
MrSmoer
e823122f19
fix: Move "forgot_password"-link to fix login tab order
...
Previously hitting tab in the username field set the focus to the "forgot password" link. Only on the next hit the password field was selected.
This is an issue for some password managers (keepassdx android keyboard) and not as nice for accessibility.
Now the forgot link is below the sign up link at the bottom of the page.
Using "tabindex" didn't work properly with the templating engine because many elements get assigned a tabindex of "0" by default disrupting the tab selection sequence.
2024-11-10 02:24:58 +01:00
Gusted
ef9df01cd2
Merge pull request '[v9.0/forgejo] [THEME] Copy ansi terminal colours from gitea to forgejo themes' ( #5882 ) from bp-v9.0/forgejo-e58d5d4 into v9.0/forgejo
...
Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/5882
Reviewed-by: Gusted <gusted@noreply.codeberg.org>
2024-11-09 22:40:07 +00:00
Ragnar Groot Koerkamp
2e114bcaa0
[THEME] Copy ansi terminal colours from gitea to forgejo themes
...
(cherry picked from commit e58d5d46c1
)
2024-11-09 21:57:08 +00:00
Gusted
91a12abdaf
Merge pull request '[v9.0/forgejo] [PORT] Fix code owners will not be mentioned when a pull request comes from a forked repository (gitea#30476)' ( #5879 ) from bp-v9.0/forgejo-2efc1f5-536e192 into v9.0/forgejo
...
Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/5879
Reviewed-by: Gusted <gusted@noreply.codeberg.org>
2024-11-09 19:21:37 +00:00
Gusted
79bc6e8c35
chore: add extra integration test
...
(cherry picked from commit 536e1923b4
)
2024-11-09 18:43:38 +00:00
Lunny Xiao
770fa89dc8
[PORT] Fix code owners will not be mentioned when a pull request comes from a forked repository (gitea#30476)
...
Fix #30277
Caused by #29783
---
- Resolves #5842
- Regression from #2855
(cherry picked from commit c63060b130d34e3f03f28f4dccbf04d381a95c17)
(cherry picked from commit 2efc1f5686
)
2024-11-09 18:43:37 +00:00
Earl Warren
9a7b0c3f02
Merge pull request '[v9.0/forgejo] bug: require.Eventually must not test with assert' ( #5870 ) from bp-v9.0/forgejo-2541a94 into v9.0/forgejo
...
Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/5870
Reviewed-by: Earl Warren <earl-warren@noreply.codeberg.org>
2024-11-09 00:39:12 +00:00
Earl Warren
8c51053739
bug: require.Eventually must not test with assert
...
Otherwise it fails the test instead of retrying if the condition fails
at least once.
(cherry picked from commit 2541a943ce
)
2024-11-08 23:42:01 +00:00
Otto
3a4612cb2b
Merge pull request '[v9.0/forgejo] chore(renovate): only run if renovate workflow changed' ( #5861 ) from bp-v9.0/forgejo-2eeb2fc into v9.0/forgejo
...
Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/5861
Reviewed-by: Michael Kriese <michael.kriese@gmx.de>
2024-11-08 12:58:13 +00:00
Michael Kriese
c0113bfbbe
chore(renovate): only run if renovate workflow changed
...
(cherry picked from commit 2eeb2fcd35
)
2024-11-08 12:43:09 +00:00
Renovate Bot
08396d566b
Update dependency happy-dom to v15.10.2 [SECURITY] (v9.0/forgejo) ( #5854 )
...
Co-authored-by: Renovate Bot <forgejo-renovate-action@forgejo.org>
Co-committed-by: Renovate Bot <forgejo-renovate-action@forgejo.org>
2024-11-08 06:39:14 +00:00
Otto
66b6917923
Merge pull request '[v9.0/forgejo] fix: issue labels are not set after deleting one label' ( #5844 ) from bp-v9.0/forgejo-db899c1-f06bdb0 into v9.0/forgejo
...
Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/5844
Reviewed-by: Otto <otto@codeberg.org>
2024-11-07 11:22:14 +00:00
Earl Warren
397b3cf88f
chore(refactor): split ReloadLabels out of LoadLabels in issue model
...
Functions modifying the labels in the database (DeleteIssueLabel,
NewIssueLabels, NewIssueLabel, ReplaceIssueLabels) need to force
reload them. Instead of:
issue.isLabelsLoaded = false
issue.Labels = nil
if err = issue.LoadLabels(ctx); err != nil {
return err
}
They can now use:
if err = issue.ReloadLabels(ctx); err != nil {
return err
}
(cherry picked from commit f06bdb0552
)
2024-11-07 10:38:36 +00:00
Earl Warren
bcb72df356
fix: issue labels are not set after deleting one label
...
Because issue.isLabelsLoaded = false is missing, LoadLabels is a noop
and the issue.Labels is nil.
(cherry picked from commit db899c19d8
)
2024-11-07 10:38:36 +00:00
Earl Warren
ed2d5f6b73
Merge pull request '[v9.0/forgejo] fix: labels are missing in the pull request payload removing a label' ( #5834 ) from bp-v9.0/forgejo-c801838 into v9.0/forgejo
...
Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/5834
Reviewed-by: Earl Warren <earl-warren@noreply.codeberg.org>
2024-11-07 08:03:00 +00:00
Earl Warren
eda6b436dc
fix: labels are missing in the pull request payload removing a label
...
When ReplaceIssueLabels calls issue.LoadLabels it was a noop because
issue.isLabelsLoaded is still set to true because of the call to
issue.LoadLabels that was done at the beginning of the function.
(cherry picked from commit c801838690
)
2024-11-06 17:38:04 +00:00
Earl Warren
09a35a7cb8
Merge pull request '[v9.0/forgejo] Add label to Forgejo Actions PR labeled/unlabeled events and update the commit status' ( #5810 ) from bp-v9.0/forgejo-58e3c1f-66c85b7-f56fc51 into v9.0/forgejo
...
Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/5810
Reviewed-by: Otto <otto@codeberg.org>
2024-11-06 16:13:39 +00:00
Otto
a68a37f59c
Merge pull request '[v9.0/forgejo] chore(ci): deprecate legacy infrastructure supporting v*.next' ( #5823 ) from bp-v9.0/forgejo-ece87d0 into v9.0/forgejo
...
Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/5823
Reviewed-by: Otto <otto@codeberg.org>
2024-11-05 22:30:44 +00:00
Earl Warren
2b86ff6768
chore(ci): deprecate legacy infrastructure supporting v*.next
...
https://code.forgejo.org/infrastructure/k8s/ was replaced with
https://code.forgejo.org/infrastructure/k8s-cluster/
(cherry picked from commit ece87d0569
)
2024-11-05 21:43:31 +00:00
Earl Warren
8a65c4d28d
chore(release-notes): related pull requests workflow fixes
...
(cherry picked from commit f56fc51c74
)
2024-11-04 14:10:27 +00:00
Earl Warren
d624a5edd6
fix: Actions PR workflows must update the commit status
...
When a workflow has
on:
pull_request:
types:
- labeled
- unlabeled
The outcome of the workflow (success or failure) must be associated
with the head sha commit status. Otherwise it cannot be used as a
requirement for merging the pull request (branch protections).
(cherry picked from commit 66c85b7d8b
)
2024-11-04 14:10:27 +00:00
Earl Warren
11f71dcb09
fix: add label to issues and PR labeled/unlabeled events
...
When a workflow has
on:
pull_request:
types:
- labeled
- unlabeled
The payload misses the label field describing the added or removed
label.
The unlabeled event type was also incorrectly mapped to the labeled
event type.
(cherry picked from commit 58e3c1fbdb
)
2024-11-04 14:10:27 +00:00
Earl Warren
7ec30b6ee9
Merge pull request '[v9.0/forgejo] chore(ci): notify the k8s cluster about experimental releases' ( #5807 ) from earl-warren/forgejo:wip-v9.0-next-digest into v9.0/forgejo
...
Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/5807
Reviewed-by: Michael Kriese <michael.kriese@gmx.de>
2024-11-04 13:52:05 +00:00
Earl Warren
13a5d9f3af
[v9.0/forgejo] chore(ci): notify the k8s cluster about experimental releases
...
This is in preparation of the migration of the v*.next.forgejo.org
instances currently managed at https://code.forgejo.org/infrastructure/k8s
The key difference is that the former system relies on ad-hoc scripts
and creates one k8s cluster for each instance, sharing nothing between
them.
The newer k8s cluster is used for all and requires significantly less
ad-hoc tooling.
See also:
* https://code.forgejo.org/infrastructure/next-digest
* https://code.forgejo.org/infrastructure/k8s-cluster/src/branch/main/k8s.md#updating-v-next-forgejo-org
(cherry picked from commit dab156b452
)
2024-11-04 14:30:53 +01:00
Gusted
a429dbad98
Merge pull request '[v9.0/forgejo] fix: support www.github.com
for migrations' ( #5800 ) from bp-v9.0/forgejo-284ffe4 into v9.0/forgejo
...
Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/5800
Reviewed-by: Michael Kriese <michael.kriese@gmx.de>
2024-11-03 18:21:04 +00:00
Michael Kriese
0c0fd333f3
fix: support www.github.com
for migrations
...
(cherry picked from commit 284ffe4e00
)
2024-11-03 17:28:30 +00:00
Earl Warren
d96cef1ac4
Merge pull request '[v9.0/forgejo] fix: reset history.scrollRestoration
if set to manual
and no issue anchor in url' ( #5753 ) from bp-v9.0/forgejo-ec4a0e1 into v9.0/forgejo
...
Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/5753
Reviewed-by: Otto <otto@codeberg.org>
Reviewed-by: Michael Kriese <michael.kriese@gmx.de>
2024-11-01 10:10:25 +00:00
Earl Warren
3f58b8d1bd
Merge pull request '[v9.0/forgejo] fix git-grep for code search when git version is below 2.38' ( #5759 ) from earl-warren/forgejo:wip-v9.0-grep into v9.0/forgejo
...
Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/5759
Reviewed-by: Otto <otto@codeberg.org>
2024-10-31 21:12:18 +00:00
Shiny Nematoda
908bd64238
fix(grep): fix git-grep for code search when git version is below 2.38
...
(cherry picked from commit f2ab4ff83a
)
Conflicts:
modules/git/grep.go
trivial context conflict
2024-10-31 21:26:03 +01:00
Earl Warren
be36f91bb7
Merge pull request '[v9.0/forgejo] i18n: update of translations from Codeberg Translate' ( #5748 ) from bp-v9.0/forgejo-031451e into v9.0/forgejo
...
Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/5748
Reviewed-by: Otto <otto@codeberg.org>
2024-10-31 06:38:23 +00:00
Michael Kriese
8e4536fd98
fix: reset history.scrollRestoration
if set to manual
and no issue anchor in url
...
(cherry picked from commit ec4a0e1b6e
)
2024-10-31 02:37:43 +00:00
Codeberg Translate
f043fb4495
i18n: update of translations from Codeberg Translate ( #5681 )
...
Co-authored-by: 0ko <0ko@users.noreply.translate.codeberg.org>
Co-authored-by: artnay <artnay@users.noreply.translate.codeberg.org>
Co-authored-by: emansije <emansije@users.noreply.translate.codeberg.org>
Co-authored-by: Gusted <postmaster@gusted.xyz>
Co-authored-by: Outbreak2096 <Outbreak2096@users.noreply.translate.codeberg.org>
Co-authored-by: Benedikt Straub <Nordfriese@users.noreply.translate.codeberg.org>
Co-authored-by: Fjuro <fjuro@alius.cz>
Co-authored-by: Juno Takano <jutty@users.noreply.translate.codeberg.org>
Co-authored-by: Bálint Gonda <balinteus@gmail.com>
Co-authored-by: Wuzzy <Wuzzy@users.noreply.translate.codeberg.org>
Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/5681
Reviewed-by: 0ko <0ko@noreply.codeberg.org>
Co-authored-by: Codeberg Translate <translate@noreply.codeberg.org>
Co-committed-by: Codeberg Translate <translate@noreply.codeberg.org>
(cherry picked from commit 031451e740
)
2024-10-30 15:15:39 +00:00
Earl Warren
1dc03cc1c3
Merge pull request '[v9.0/forgejo] use constant time check for internal token' ( #5724 ) from bp-v9.0/forgejo-53231ba into v9.0/forgejo
...
Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/5724
Reviewed-by: Earl Warren <earl-warren@noreply.codeberg.org>
2024-10-28 08:03:48 +00:00
Earl Warren
e4dac6a6ab
Merge pull request '[v9.0/forgejo] add permission check to 'delete branch after merge'' ( #5721 ) from bp-v9.0/forgejo-266e0b2 into v9.0/forgejo
...
Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/5721
Reviewed-by: Earl Warren <earl-warren@noreply.codeberg.org>
2024-10-28 07:24:05 +00:00
Earl Warren
ff585d0a20
Merge pull request '[gitea] week 2024-44-v9.0 cherry pick (gitea/main -> v9.0/forgejo)' ( #5715 ) from earl-warren/wcp/2024-44-v9.0 into v9.0/forgejo
...
Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/5715
2024-10-28 06:59:58 +00:00
Gusted
5f9a2ad1db
fix(sec): use constant time check for internal token
...
(cherry picked from commit 53231bad61
)
2024-10-28 06:17:25 +00:00
Gusted
618eb8e72a
security: add permission check to 'delete branch after merge'
...
- Add a permission check that the doer has write permissions to the head
repository if the the 'delete branch after merge' is enabled when
merging a pull request.
- Unify the checks in the web and API router to `DeleteBranchAfterMerge`.
- Added integration tests.
(cherry picked from commit 266e0b2ce9
)
2024-10-28 06:04:45 +00:00
Earl Warren
d763886dae
chore(release-notes): notes for the week 2024-44-v9.0 weekly cherry pick
2024-10-27 12:05:14 +01:00
Lunny Xiao
768402c884
Fix disable 2fa bug ( #32320 )
...
(cherry picked from commit 2abdbe88b5d16dcb345d27b73f1d9738f2d826dd)
2024-10-27 11:57:08 +01:00
Lunny Xiao
9c6f2a132d
Add warn log when deleting inactive users ( #32318 )
...
Add log for the problem #31480
(cherry picked from commit a264c46fb04112c5ec2c1b2acd523a2e4450da40)
Conflicts:
- services/user/user.go
Resolved by manually adding the log line.
2024-10-27 11:54:36 +01:00