Christopher Homberger
b650ca9239
Merge branch 'main' of https://github.com/go-gitea/gitea into workflow-webhook-api
2025-03-21 13:19:13 +01:00
Christopher Homberger
a983d34622
fix workflow_run action event processing
2025-03-21 13:09:38 +01:00
Christopher Homberger
6df185423d
..
2025-03-21 12:27:21 +01:00
Christopher Homberger
5a0f4c9869
add other webhook types
2025-03-21 12:15:06 +01:00
Lunny Xiao
a4df01b580
Optimize total count of feed when loading activities in user dashboard. ( #33841 )
...
Two SQLs are very slow when `action` table have over 5M records.
```
database duration=1.8881s db.sql="SELECT created_unix DIV 900 * 900 AS timestamp, count(user_id) as contributions FROM `action` WHERE user_id=? AND act_user_id=? AND (created_unix > ?) GROUP BY timestamp ORDER BY timestamp"
database duration=1.5408s db.sql="SELECT count(*) FROM `action` WHERE (user_id = ?) AND (is_deleted = ?)"
```
This will cache the count for the first loading or when the activities
changed.
2025-03-20 10:46:18 -07:00
Lunny Xiao
ef0970506f
Extract code to their own functions for push update ( #33944 )
2025-03-20 16:57:04 +00:00
Lunny Xiao
a9e8ac0fe0
Don't create duplicated functions for code repositories and wiki repositories ( #33924 )
...
Fix
https://github.com/go-gitea/gitea/pull/33910#pullrequestreview-2688913865
This PR changed the Repositroy interface in `gitrepo` package which
makes it only focus the relative path in the disk and abstract whether
it's a wiki repository or not.
2025-03-19 11:17:19 -07:00
Christopher Homberger
22bfd96b9c
fix keda scaler compat
2025-03-18 21:03:33 +01:00
Christopher Homberger
875c7745e4
wip test and fixes
2025-03-18 20:26:22 +01:00
Christopher Homberger
ca6bbc6c6d
wip
2025-03-17 22:43:23 +01:00
Christopher Homberger
c3f6f13377
prevent endless workflow_run trigger
2025-03-17 22:23:14 +01:00
Christopher Homberger
605ed19b9b
invoke workflow_run
2025-03-17 22:15:47 +01:00
Christopher Homberger
171efe55c5
update context with name
2025-03-17 21:59:18 +01:00
Christopher Homberger
da738eaa74
webhook deliver the workflow field
2025-03-17 21:58:29 +01:00
Christopher Homberger
658583a584
Merge branch 'main' of https://github.com/go-gitea/gitea into workflow-webhook-api
2025-03-17 21:49:12 +01:00
Christopher Homberger
fb8a221d7f
Move GetActionWorkflow to convert
2025-03-17 20:40:27 +01:00
John Smith
8f051d598c
Added Description Field for Secrets and Variables ( #33526 )
...
Fixes #33484
---------
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
2025-03-17 19:24:54 +00:00
Christopher Homberger
392baec50b
remove dead code
2025-03-17 20:18:12 +01:00
Christopher Homberger
295bf45d5c
cleanup and fix webhook type bug
2025-03-17 20:17:42 +01:00
Christopher Homberger
a178e4be7a
use cached task instance if available
2025-03-17 20:13:33 +01:00
Christopher Homberger
20f5d6ee95
use ToActionsStatus
2025-03-17 20:08:12 +01:00
Christopher Homberger
988cafe780
remove duplicated code
2025-03-17 20:06:19 +01:00
wxiaoguang
9d7c02f9f7
Try to figure out attribute checker problem ( #33901 )
...
For #31600
2025-03-17 11:59:34 -07:00
Christopher Homberger
013a0af385
wip
2025-03-17 17:27:25 +01:00
Lunny Xiao
7fd44a85ca
Move hooks function to gitrepo and reduce expose repopath ( #33890 )
...
Extract from #28966
Follow #33874
2025-03-16 16:12:55 +00:00
Lunny Xiao
c88e71c1d2
Refactor functions to reduce repopath expose ( #33892 )
2025-03-16 03:14:56 +00:00
Lunny Xiao
0056fdb942
Move git references checking to gitrepo packages to reduce expose of repository path ( #33891 )
2025-03-15 19:48:59 -07:00
Lunny Xiao
3e2e7bf4e5
Add lock for a repository pull mirror ( #33876 )
...
Fix #33647
This PR add a global lock for repository pulling mirror.
2025-03-15 10:23:18 -07:00
Kerwin Bryant
92f997ce6b
Add file tree to file view page ( #32721 )
...
Resolve #29328
This pull request introduces a file tree on the left side when reviewing
files of a repository.
---------
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
2025-03-15 16:26:49 +08:00
Christopher Homberger
edb24592fc
wip event
2025-03-14 21:07:36 +01:00
ChristopherHX
65e2411394
Feature: Ephemeral action runners ( #33570 )
...
* This includes a runner mock test for hardend PickTask behavior like
described in my proposal
* Runner register ephemeral flag introduced in
https://gitea.com/gitea/act_runner/pulls/649
Closes #32461
2025-03-14 12:27:24 -07:00
Lunny Xiao
55cc649d3d
Add abstraction layer to delete repository from disk ( #33879 )
...
Extract from #28966
Follow #33874
2025-03-14 18:38:55 +00:00
wxiaoguang
cb6b33c9cd
Ignore trivial errors when updating push data ( #33864 )
...
Fix #23213
2025-03-14 08:36:39 +00:00
Lunny Xiao
9c673d066c
Add abstraction layer to check if the repository exists on disk ( #33874 )
...
Extract from #28966
This PR uses `gitrepo.IsRepositoryExist` instead of `util.IsExist` to
detect whether the repository exist in disk. This will move `RepoPath`
detail behind of package `gitrepo` to make it easier to do possible
changes where storing the repositories.
No code change
2025-03-14 03:00:56 +00:00
Lunny Xiao
1e7248047c
Pull request updates will also trigger code owners review requests ( #33744 )
...
Fix #33490
It will only read the changed file on the pushed commits but not all the
files of this PR.
---------
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
2025-03-13 19:36:14 -07:00
TheFox0x7
5d65b9060b
remove context from retry downloader ( #33871 )
...
follow up to https://github.com/go-gitea/gitea/pull/33399 as I
apparently missed this one.
2025-03-14 00:28:57 +00:00
wxiaoguang
3996518ed4
Refactor cache-control ( #33861 )
...
And fix #21391
2025-03-13 07:04:50 +08:00
ChristopherHX
651ef66966
Add workflow_job webhook ( #33694 )
...
Provide external Integration information about the Queue lossly based on
https://docs.github.com/en/webhooks/webhook-events-and-payloads?actionType=completed#workflow_job
Naming conflicts between GitHub & Gitea are here, Blocked => Waiting,
Waiting => Queued
Rationale Enhancement for ephemeral runners management #33570
2025-03-11 10:40:38 -07:00
ChristopherHX
a92d5f65ce
Fix auto concurrency cancellation skips commit status updates ( #33764 )
...
* add missing commit status
* conflicts with concurrency support
Closes #33763
Co-authored-by: Giteabot <teabot@gitea.io>
2025-03-10 15:58:48 -07:00
wxiaoguang
657239b480
Fix material icon & diff highlight ( #33844 )
2025-03-10 22:34:48 +08:00
Lunny Xiao
ae63568ce3
Move notifywatch to service layer ( #33825 )
...
No logic change.
2025-03-10 00:54:25 +00:00
wxiaoguang
7290bfaccb
Only keep popular licenses ( #33832 )
...
Fix #33467
2025-03-10 06:40:37 +08:00
Dustin Firebaugh
3f1f808b9e
Full-file syntax highlighting for diff pages ( #33766 )
...
Fix #33358 , fix #21970
This adds a step in the `GitDiffForRender` that does syntax highlighting for the
entire file and then only references lines from that syntax highlighted
code. This allows things like multi-line comments to be syntax
highlighted correctly.
---------
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
2025-03-09 12:51:58 +08:00
wxiaoguang
6f13331754
Improve theme display ( #30671 )
...
Document: https://gitea.com/gitea/docs/pulls/180

2025-03-08 21:38:11 +00:00
TheFox0x7
4c4c56c7cd
Decouple context from repository related structs ( #33823 )
...
Calls that required context implicitly are made to pass it as argument
2025-03-08 13:12:46 -08:00
wxiaoguang
4ed71eb754
Improve log format ( #33814 )
2025-03-08 21:47:11 +08:00
wxiaoguang
6422f05a4e
Decouple diff stats query from actual diffing ( #33810 )
...
The diff stats are no longer part of the diff generation.
Use `GetDiffShortStat` instead to get the total number of changed files,
added lines, and deleted lines.
As such, `gitdiff.GetDiff` can be simplified:
It should not do more than expected.
And do not run "git diff --shortstat" for pull list. Fix #31492
2025-03-08 17:36:08 +08:00
Lunny Xiao
1b2dffff8e
Add global lock for migrations to make upgrade more safe with multiple replications ( #33706 )
2025-03-07 21:08:53 +00:00
TheFox0x7
e7cf62f2f7
remove context from mail struct ( #33811 )
...
it can be passed by argument instead
2025-03-06 20:57:00 +00:00
Lunny Xiao
0453177b61
Refactor: move part of updating protected branch logic to service layer ( #33742 )
2025-03-05 19:15:40 +00:00