aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* Make pull request and issue history more compact (#34588)silverwind2025-06-031-5/+6
| | | Reduced spacing around history entries and inside the commits list, also fixed unequal horizontal spacing inside the commit badge.
* Refactor some tests (#34580)wxiaoguang2025-06-0323-148/+58
| | | | 1. use `test.MockVariableValue` as much as possible 2. avoid `time.Sleep` as much as possible
* Do not mutate incoming options to SearchRepositoryByName (#34553)Philip Peterson2025-06-0225-89/+91
| | | | | | | | | | | | | | Similar to #34544, this PR changes the `opts` argument in `SearchRepositoryByName()` to be passed by value instead of by pointer, as its mutations do not escape the function scope and are not used elsewhere. This simplifies reasoning about the function and avoids unnecessary pointer usage. This insight emerged during an initial attempt to refactor `RenderUserSearch()`, which currently intermixes multiple concerns. --------- Co-authored-by: Philip Peterson <philip-peterson@users.noreply.github.com>
* Fix/improve avatar sync from LDAP (#34573)Râu Cao2025-06-022-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | This fixes 3 issues I encountered when debugging problems with our LDAP sync: 1. The comparison of the hashed image data in `IsUploadAvatarChanged` is wrong. It seems to be from before avatar hashing was changed and unified in #22289. This results in the function always returning `true` for any avatars, even if they weren't changed. 2. Even if there's no avatar to upload (i.e. no avatar available for the LDAP entry), the upload function would still be called for every single user, only to then fail, because the data isn't valid. This is unnecessary. 3. Another small issue is that the comparison function (and thus hashing of data) is called for every user, even if there is no avatar attribute configured at all for the LDAP source. Thus, I switched the condition nesting, so that no cycles are wasted when avatar sync isn't configured in the first place. I also added a trace log for when there is actually a new avatar being uploaded for an existing user, which is now only shown when that is actually the case. --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Fix some trivial problems (#34579)wxiaoguang2025-06-028-12/+46
|
* Retain issue sort type when a keyword search is introduced (#34559)badhezi2025-06-021-0/+1
| | | Fixes #34523
* Always use an empty line to separate the commit message and trailer (#34512)Jim Lin2025-06-023-5/+63
| | | | | | | | | If the message from form.MergeMessageField is empty, we will miss a "\n" between the title and the "Co-authored-by:" line. The title and message should have a blank line between of them. --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Fix line-button issue after file selection in file tree (#34574)Kerwin Bryant2025-06-023-11/+35
| | | | | | | | Fix the issue where the line-button fails to work after selecting a file from the file tree. --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* [skip ci] Updated translations via CrowdinGiteaBot2025-05-312-0/+4
|
* Fix doctor deleting orphaned issues attachments (#34142)Lunny Xiao2025-05-305-154/+93
| | | | Fix the bug when deleting orphaned issues attachments. The attachments maybe stored on other storages service rather than disk.
* [skip ci] Updated translations via CrowdinGiteaBot2025-05-302-0/+3
|
* Fix actions skipped commit status indicator (#34507)badhezi2025-05-2810-249/+112
| | | | | Addresses https://github.com/go-gitea/gitea/issues/34500 Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Clean up "file-view" related styles (#34558)wxiaoguang2025-05-286-77/+73
| | | | Move "file-view" and "code-view" related styles to their own file, remove unnecessary `!important`
* Add "View workflow file" to Actions list page (#34538)NorthRealm2025-05-287-28/+47
| | | | | | | | | | This PR adds "View workflow file" to Actions list page, and replaces the redundant link. Related #34530 --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Do not mutate incoming options to RenderUserSearch and SearchUsers (#34544)Philip Peterson2025-05-2712-31/+31
| | | | | | | | | | | This PR changes the `opts` argument in `SearchUsers()` to be passed by value instead of by pointer, as its mutations do not escape the function scope and are not used elsewhere. This simplifies reasoning about the function and avoids unnecessary pointer usage. This insight emerged during an initial attempt to refactor `RenderUserSearch()`, which currently intermixes multiple concerns. Co-authored-by: Philip Peterson <philip-peterson@users.noreply.github.com>
* Add webhook assigning test and fix possible bug (#34420)Lunny Xiao2025-05-273-185/+235
| | | Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Fix possible nil description of pull request when migrating from CodeCommit ↵Lunny Xiao2025-05-271-1/+5
| | | | | (#34541) Fix #34320
* Refactor commit reader (#34542)wxiaoguang2025-05-274-84/+68
|
* Split GetLatestCommitStatus as two functions (#34535)Lunny Xiao2025-05-2615-30/+73
| | | | | | | | Extract from #34531. This will reduce unnecessary count operation in databases. --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Don't display error log when .git-blame-ignore-revs doesn't exist (#34457)Lunny Xiao2025-05-261-18/+22
| | | Fix #34454
* Add sort option recentclose for issues and pulls (#34525)Markus Amshove2025-05-265-2/+48
| | | | | | closes #34171 Adds a new sort option `recentclose` for issues and pull requests which will return items in a descending order of when they were closed
* fix: return 201 Created for CreateVariable API responses (#34517)Bo-Yi Wu2025-05-266-42/+37
| | | | | | | | | | | | | | | | | | | - Change CreateVariable API response status from 204 No Content to 201 Created - Update related integration tests to expect 201 Created instead of 204 No Content ## :warning: BREAKING :warning: Change the response status code of the Create Variable API under both Org and Repo levels to `201` instead of 204. API SDK: https://gitea.com/gitea/go-sdk/pulls/713 --------- Signed-off-by: Bo-Yi Wu <appleboy.tw@gmail.com> Signed-off-by: appleboy <appleboy.tw@gmail.com> Co-authored-by: delvh <dev.lh@web.de>
* Actions list (#34530)NorthRealm2025-05-261-9/+17
| | | | | | | | Closes #34524 --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* [skip ci] Updated translations via CrowdinGiteaBot2025-05-261-1/+1
|
* Run integration tests against postgres 14 (#34514)silverwind2025-05-231-1/+1
| | | | | | | postgres 12 is end of life since 6 months. 13 and above are still supported but I think it's overall better if we test a more recent version of postgres because that's what new users will be running on. Ref: https://endoflife.date/postgresql
* [skip ci] Updated translations via CrowdinGiteaBot2025-05-232-1/+4
|
* Performance optimization for tags synchronization (#34355)Lunny Xiao2025-05-227-190/+31
| | | | | | | | | The tags synchronization is very slow for a non-mirror repository with many tags especially forking. This PR make all repositories' tags synchronization use the same function and remove the low performance synchronization function. The commit count of tag now will not be stored into database when syncing. Since the commits count will always be read from cache or git data, the `NumCommits` in the release table will be updated for the first read from git data.
* Fix possible panic (#34508)Lunny Xiao2025-05-223-25/+65
|
* [skip ci] Updated translations via CrowdinGiteaBot2025-05-221-0/+1
|
* [skip ci] Updated translations via CrowdinGiteaBot2025-05-211-0/+64
|
* Fix ephemeral runner deletion (#34447)ChristopherHX2025-05-208-12/+172
| | | | | | | | | * repository deletion, delete ephemeral runners with active tasks as well skips regular cleanup * user deletion, delete ephemeral runners with active tasks as well skips regular cleanup * delete ephemeral runners once status changes to done * You no longer see used ephemeral runners after the task is done * if you see one the cron job takes care of it
* ui: add a default tab on repo header when migrating (#34503)a10121127962025-05-202-1/+10
| | | Signed-off-by: a1012112796 <1012112796@qq.com>
* Use run-name and evaluate workflow variables (#34301)badhezi2025-05-207-33/+293
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | This addresses https://github.com/go-gitea/gitea/issues/34247 depends on https://gitea.com/gitea/act/pulls/137 I couldn't find any previous implementation for `run-name` support on workflows so I created one. Key points: All dispatched workflows, scheduled workflows and detected workflows (from different hooks) will use and evaluate `run-name` if exists, with the corresponding gitea context and variables. This will be used as the Action run title and replace the default commit message being used today. Had to change act package jobparser (see link above) and create two helpers https://github.com/go-gitea/gitea/blob/3a1320c70df82ae88e286612c1646cffb8e2c343/models/actions/utils.go#L86 and https://github.com/go-gitea/gitea/blob/3a1320c70df82ae88e286612c1646cffb8e2c343/services/actions/context.go#L169 to pass the correct types to [GenerateGiteaContext](https://github.com/go-gitea/gitea/pull/34301/files#diff-9c9c27cb61a33e55ad33dc2c2e6a3521957a3e5cc50ddf652fdcd1def87b044dR86) and [WithGitContext](https://gitea.com/gitea/act/src/commit/65c232c4a5a40e59e257ab5d956b32585f0405d7/pkg/jobparser/jobparser.go#L84) respectively. <img width="1336" alt="Screenshot 2025-04-28 at 17 13 01" src="https://github.com/user-attachments/assets/73cb03d0-23a0-4858-a466-bbf0748cea98" />
* feat(api): add date range filtering to commit retrieval endpoints (#34497)Bo-Yi Wu2025-05-198-10/+76
| | | | | | | | | | | | | | | - Add support for filtering commits by date range via new "since" and "until" parameters - Update API endpoints and command logic to handle the new parameters for fetching commits within given dates - Extend API documentation and Swagger specs to describe the new "since" and "until" query parameters - Refactor related function signatures and implementations to accept and pass "since" and "until" values --------- Signed-off-by: appleboy <appleboy.tw@gmail.com> Signed-off-by: Bo-Yi Wu <appleboy.tw@gmail.com>
* Export repo's manual merge settings (#34502)Adam Majer2025-05-193-0/+16
|
* [skip ci] Updated translations via CrowdinGiteaBot2025-05-191-0/+3
|
* Fix edithook api can not update package, status and workflow_job events (#34495)ChristopherHX2025-05-181-55/+37
| | | * the origin of this problem is duplicated code
* Fix url validation in webhook add/edit API (#34492)Lunny Xiao2025-05-173-0/+112
|
* Add R-HNF to the TRANSLATORS file (#34494)Ryo Hanafusa2025-05-171-0/+1
| | | | | | | | | | | | I would like to be added to the TRANSLATORS file. Here are my related activities: * https://crowdin.com/profile/R-HNF/activity * commit: [skip ci] Updated translations via Crowdin 319d03fbc049de34a6fa0bc3019107ec5b724ff2 I also referred to the following PRs: * #8451 * #8292
* Add missing setting load in dump-repo command (#34479)Lunny Xiao2025-05-161-0/+5
| | | Fix #34465
* nix flake update (#34476)techknowlogick2025-05-161-3/+3
|
* Fix get / delete runner to use consistent http 404 and 500 status (#34480)ChristopherHX2025-05-162-18/+35
| | | | * previously deleting an already deleted runner returned http 500 * previously any database error for the get endpoint was http 404 and never 500
* Change "rejected" to "changes requested" in 3rd party PR review notification ↵Sebastian Weigand2025-05-151-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (#34481) This PR changes 3rd party notifications wording on a PR review that requests changes and can be considered a follow up for #5858 to also fix #5857 in 3rd party notifications. The difference in the actual notification would be the following: ```diff - Pull request review rejected + Pull request review changes requested ``` While this is a simple string change at first look, it has a deeper UX meaning. # Motivation We could observe that some developers are hesitant to press the "Request changes" button since their peers first see that their changes were rejected, thus a more appropriate wording that also falls in line with the meaning and UI would be beneficial. ## Meaning Pressing the `Request changes` button in a PR review means that as a reviewer you are willing to merge the general change in a PR if changes requested review comments are implemented. Rejecting a PR on the other hand would be equivalent with closing it since that change isn't welcome at all (e.g. out of scope feature). ## Sync with UI The UI button says `request changes` and the other options ![image](https://github.com/user-attachments/assets/3766cc89-40d7-4c5e-9ff7-a0e1f6991ea6) ## Considered Problems This might break some automation for users who rely on string matching.
* Add migrations tests (#34456)Lunny Xiao2025-05-154-2/+99
| | | | | Fix #34455 Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Fix project board view (#34470)wxiaoguang2025-05-151-17/+9
| | | Fix #34469
* [skip ci] Updated translations via CrowdinGiteaBot2025-05-153-0/+18
|
* Fix Workflow run Not Found page (#34459)NorthRealm2025-05-141-4/+4
| | | | | Related: https://github.com/go-gitea/gitea/pull/34337#issuecomment-2863593738 https://github.com/go-gitea/gitea/pull/34337#discussion_r2086332493
* [skip ci] Updated translations via CrowdinGiteaBot2025-05-141-0/+4
|
* Add endpoint deleting workflow run (#34337)NorthRealm2025-05-1322-43/+691
| | | | | | | | | | | Add endpoint deleting workflow run Resolves #26219 /claim #26219 --------- Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com> Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Fix remove org user failure on mssql (#34449)ChristopherHX2025-05-145-57/+42
| | | | | | | | | | | * mssql does not support fetching 0 repositories * remove paging by NumRepos that might be 0 * extend admin api test to purge user 2 Fixes #34448 --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>