3318001880 
					 
					
						
						
							
							Fix fullscreen for action  ( #25200 )  
						
						... 
						
						
						
						An error occurs when clicking on `show full screen` on action page.
<img width="1440" alt="Screen Shot 2023-06-12 at 13 06 52"
src="https://github.com/go-gitea/gitea/assets/17645053/1d4ded3c-fb77-4dd8-9201-24d0696f96eb ">
class name has changed in #25134 , so the selector is not working. 
Enhance the selectors to fix this. 
						
						
					 
					
						2023-06-12 10:18:01 +00:00 
						 
				 
			
				
					
						
					 
					
						
						
							
						
						623b3b590e 
					 
					
						
						
							
							Button and color enhancements ( #24989 )  
						
						... 
						
						
						
						- Various corrections to button styles, especially secondary
- Remove focus highlight, it's annoying when it stays on button after
press
- Clearly define ghost and link buttons with demos in devtest
- Remove black, grey and tertiary buttons, they should not be used
- Make `arc-green` slightly darker
<img width="1226" alt="image"
src="https://github.com/go-gitea/gitea/assets/115237/8d89786a-01ab-40f8-ae5a-e17f40e35084 ">
<img width="1249" alt="image"
src="https://github.com/go-gitea/gitea/assets/115237/83651e6d-3c27-46ff-b8bd-ff344d70e949 ">
---------
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
Co-authored-by: Giteabot <teabot@gitea.io> 
						
						
					 
					
						2023-06-09 08:37:47 +00:00 
						 
				 
			
				
					
						
					 
					
						
						
							
						
						1ea5c8b0ff 
					 
					
						
						
							
							Add show timestamp/seconds and fullscreen options to action page ( #24876 )  
						
						... 
						
						
						
						Part of #24728 
- The timestamp shows local time and is parsed by `date.toLocaleString`;
- "show seconds" and "show timestamps" are mutually exclusive, and they
can be both hidden.
https://github.com/go-gitea/gitea/assets/17645053/89531e54-37b7-4400-a6a0-bb3cc69eb6f5 
Update for timestamp format:
<img width="306" alt="Screen Shot 2023-05-25 at 09 07 47"
src="https://github.com/go-gitea/gitea/assets/17645053/2d99768d-d39c-4c9e-81a2-7bc7470399dd ">
---------
Co-authored-by: silverwind <me@silverwind.io>
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com> 
						
						
					 
					
						2023-05-30 20:38:55 +00:00 
						 
				 
			
				
					
						
					 
					
						
						
							
						
						e06f3d2ee5 
					 
					
						
						
							
							Enable vue/html-closing-bracket-spacing eslint rule ( #24987 )  
						
						... 
						
						
						
						Enable
[`vue/html-closing-bracket-spacing`](https://eslint.vuejs.org/rules/html-closing-bracket-spacing.html )
and set it to never add any useless spaces inside tags. All issues were
fixed automatically with `make lint-js-fix`. 
						
						
					 
					
						2023-05-29 16:58:53 +00:00 
						 
				 
			
				
					
						
					 
					
						
						
							
						
						1fd7e3d6be 
					 
					
						
						
							
							Improve Actions CSS ( #24864 )  
						
						... 
						
						
						
						- Various color tweaks
- Add sticky positioning to left sidebar, right header and right step
header
- Adjust margins and border radiuses
<img width="1235" alt="Screenshot 2023-05-23 at 11 18 06"
src="https://github.com/go-gitea/gitea/assets/115237/f601b00d-c7f2-43de-89f2-3ac55f2d9cdc ">
<img width="1239" alt="Screenshot 2023-05-23 at 11 18 18"
src="https://github.com/go-gitea/gitea/assets/115237/a2d24cc9-29fa-4c17-906b-84feea14b889 ">


---------
Co-authored-by: yp05327 <576951401@qq.com> 
						
						
					 
					
						2023-05-24 09:00:29 +00:00 
						 
				 
			
				
					
						
					 
					
						
						
							
						
						a9d417341c 
					 
					
						
						
							
							Run stylelint on .vue files ( #24865 )  
						
						... 
						
						
						
						- Run stylelint on .vue files
- Fix discovered issues
- Suppress warning spam from `declaration-strict-value` rule
Co-authored-by: Giteabot <teabot@gitea.io> 
						
						
					 
					
						2023-05-23 13:54:21 +00:00 
						 
				 
			
				
					
						
					 
					
						
						
							
						
						da461b5a08 
					 
					
						
						
							
							Improvements for action detail page ( #24718 )  
						
						... 
						
						
						
						Close  #24625  
Main changes:
1. For the left panel, show rerun icon only on hover, and add style when
the job is selected, and removed icon on the "rerun all" button and
modify the text on the button
https://github.com/go-gitea/gitea/assets/17645053/cc437a17-d2e9-4f1b-a8cf-f56e53962767 
2. Adjust fonts, and add on hover effects to the log lines. And add
loading effect when the job is done and the job step log is expanded for
the first time. (With reference to github)
https://github.com/go-gitea/gitea/assets/17645053/2808d77d-f402-4fb0-8819-7aa0a018cf0c 
3. Add `gt-ellipsis` to `step-summary-msg` and `job-brief-name`
<img width="898" alt="ellipsis"
src="https://github.com/go-gitea/gitea/assets/17645053/e2fb7049-3125-4252-970d-15b0751febc7 ">
4. Fixed
https://github.com/go-gitea/gitea/issues/24625#issuecomment-1541380010 
by adding explicit conditions to `ActionRunStatus.vue` and `status.tmpl`
5. Adjust some css styles
---------
Co-authored-by: silverwind <me@silverwind.io> 
					
						2023-05-22 12:17:24 +08:00 
						 
				 
			
				
					
						
					 
					
						
						
							
						
						c757765a9e 
					 
					
						
						
							
							Implement actions artifacts ( #22738 )  
						
						... 
						
						
						
						Implement action artifacts server api.
This change is used for supporting
https://github.com/actions/upload-artifact  and
https://github.com/actions/download-artifact  in gitea actions. It can
run sample workflow from doc
https://docs.github.com/en/actions/using-workflows/storing-workflow-data-as-artifacts .
The api design is inspired by
https://github.com/nektos/act/blob/master/pkg/artifacts/server.go  and
includes some changes from gitea internal structs and methods.
Actions artifacts contains two parts:
- Gitea server api and storage (this pr implement basic design without
some complex cases supports)
- Runner communicate with gitea server api (in comming)
Old pr https://github.com/go-gitea/gitea/pull/22345  is outdated after
actions merged. I create new pr from main branch.

Add artifacts list in actions workflow page. 
						
						
					 
					
						2023-05-19 21:37:57 +08:00 
						 
				 
			
				
					
						
					 
					
						
						
							
						
						53a00017bb 
					 
					
						
						
							
							Fix flash of unstyled content in action view page ( #24712 )  
						
						... 
						
						
						
						# Before

# After

Ref: https://github.com/go-gitea/gitea/issues/24625 
Signed-off-by: Yarden Shoham <git@yardenshoham.com>
Co-authored-by: Giteabot <teabot@gitea.io> 
						
						
					 
					
						2023-05-14 14:58:59 +00:00 
						 
				 
			
				
					
						
					 
					
						
						
							
						
						ae9ac50072 
					 
					
						
						
							
							Make the actions control button look like an actual button ( #24611 )  
						
						... 
						
						
						
						- Follows #24595 
# Before



# After



---------
Signed-off-by: Yarden Shoham <git@yardenshoham.com>
Co-authored-by: Giteabot <teabot@gitea.io>
Co-authored-by: silverwind <me@silverwind.io>
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com> 
						
						
					 
					
						2023-05-10 08:09:23 +00:00 
						 
				 
			
				
					
						
					 
					
						
						
							
						
						de7dcc7cd9 
					 
					
						
						
							
							Add a tooltip to the job rerun button ( #24617 )  
						
						... 
						
						
						
						This one doesn't look very good as a real button (at least not in the
ways I tried), so I've opted to simply add a tooltip for it.
# Before

# After

Signed-off-by: Yarden Shoham <git@yardenshoham.com> 
						
						
					 
					
						2023-05-10 07:37:10 +00:00 
						 
				 
			
				
					
						
					 
					
						
						
							
						
						9a0652f0b2 
					 
					
						
						
							
							Attach a tooltip to the action status icon ( #24614 )  
						
						... 
						
						
						
						To clearly communicate the current state of the action






---------
Signed-off-by: Yarden Shoham <git@yardenshoham.com> 
						
						
					 
					
						2023-05-09 21:39:16 +02:00 
						 
				 
			
				
					
						
					 
					
						
						
							
						
						d5b2bf9044 
					 
					
						
						
							
							Update JS dependencies, add new eslint rules ( #24597 )  
						
						... 
						
						
						
						- Update all JS dependencies
- Enable new eslint rules, fix issue (some via autofix)
- Fix some missed eslint rule renames from [unicorn
v25](https://github.com/sindresorhus/eslint-plugin-unicorn/releases/tag/v25.0.0 )
- Tested Monaco, Katex, Swagger UI
---------
Co-authored-by: 6543 <6543@obermui.de>
Co-authored-by: Giteabot <teabot@gitea.io> 
						
						
					 
					
						2023-05-09 02:35:49 +00:00 
						 
				 
			
				
					
						
					 
					
						
						
							
						
						46e97986f5 
					 
					
						
						
							
							Attach a tooltip to the action control button ( #24595 )  
						
						... 
						
						
						
						The first time I saw the big red X button I thought something failed but
apparently, it was just a "Cancel" button
# Before



# After



---------
Signed-off-by: Yarden Shoham <git@yardenshoham.com>
Co-authored-by: Giteabot <teabot@gitea.io>
Co-authored-by: silverwind <me@silverwind.io> 
						
						
					 
					
						2023-05-08 23:59:59 +00:00 
						 
				 
			
				
					
						
					 
					
						
						
							
						
						9ad5b59cd9 
					 
					
						
						
							
							Do not select line numbers when selecting text from the action run logs ( #24594 )  
						
						... 
						
						
						
						- Fixes  #24578 
# Before

# After

Signed-off-by: Yarden Shoham <git@yardenshoham.com> 
						
						
					 
					
						2023-05-08 20:50:05 +02:00 
						 
				 
			
				
					
						
					 
					
						
						
							
						
						5987f00523 
					 
					
						
						
							
							Add rerun workflow button and refactor to use SVG octicons ( #24350 )  
						
						... 
						
						
						
						Changes:
- Add rerun workflow button. Then users can rerun the whole workflow by
only one-click.
- Refactor to use SVG octicons in RepoActionView.vue



---------
Co-authored-by: silverwind <me@silverwind.io>
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com> 
						
						
					 
					
						2023-05-01 22:14:20 +08:00 
						 
				 
			
				
					
						
					 
					
						
						
							
						
						68aac691c1 
					 
					
						
						
							
							Add job.duration in web ui ( #23963 )  
						
						... 
						
						
						
						

Maybe we can change the location of it. 
						
						
					 
					
						2023-04-07 18:20:50 -04:00 
						 
				 
			
				
					
						
					 
					
						
						
							
						
						aa9c920980 
					 
					
						
						
							
							Improve action log display with control chars ( #23820 )  
						
						... 
						
						
						
						Close  #23680 
Some CLI programs use "\r" and control chars to print new content in
current line.
So, the strings in one line are actually from
`\rReading...1%\rReading...5%\rReading...100%`
This PR tries to make the output better. 
					
						2023-04-01 20:57:05 +08:00 
						 
				 
			
				
					
						
					 
					
						
						
							
						
						964a057a76 
					 
					
						
						
							
							Fix checks for needs in Actions ( #23789 )  
						
						... 
						
						
						
						Fix:
- https://gitea.com/gitea/act_runner/issues/77 
- https://gitea.com/gitea/act_runner/issues/81 
Before:
<img width="1489" alt="image"
src="https://user-images.githubusercontent.com/9418365/228501567-f752cf87-a7ed-42c6-8f3d-ba741795c1fe.png ">
Highlights:
- Upgrade act to make things doable, related to
  - https://gitea.com/gitea/act/pulls/32 
  - https://gitea.com/gitea/act/pulls/33 
  - https://gitea.com/gitea/act/pulls/35 
- Make `needs` works
- Sort jobs in the original order in the workflow files 
						
						
					 
					
						2023-03-30 22:33:17 +08:00 
						 
				 
			
				
					
						
					 
					
						
						
							
						
						22fec1650a 
					 
					
						
						
							
							Add commit info in action page ( #23210 )  
						
						... 
						
						
						
						Add more commit info in action detail page.
 
						
						
					 
					
						2023-03-27 18:34:09 +08:00 
						 
				 
			
				
					
						
					 
					
						
						
							
						
						202803fc69 
					 
					
						
						
							
							Replace Less with CSS ( #23481 )  
						
						... 
						
						
						
						Ran most of the Less files through the Less compiler and Prettier and
then followed up with a round of manual fixes.
The Less compiler had unfortunately stripped all `//` style comments
that I had to restore (It did preserve `/* */` comments). Other fixes
include duplicate selector removal which were revealed after the
transpilation and which weren't caught by stylelint before but now are.
Fixes: https://github.com/go-gitea/gitea/issues/15565  
						
						
					 
					
						2023-03-14 22:20:19 -04:00 
						 
				 
			
				
					
						
					 
					
						
						
							
						
						f521e88240 
					 
					
						
						
							
							Fix actions frontend bugs (pagination, long name alignment) and small simplify ( #23370 )  
						
						... 
						
						
						
						1 Right now on actions page, the action list will not be aligned if
commit message is long. In this PR, the changes are:
- The branch tag is moved to bottom row
- Width percentage is given to make them aligned
- Show "..." if commit is longer than two lines.
- Align the status icon with the commit message with baseline
 Before:
<img width="1068" alt="截屏2023-03-08 12 23 22"
src="https://user-images.githubusercontent.com/17645053/223628534-6b9472cb-29f5-40a3-9714-c5152553049e.png ">
  
 After:
<img width="756" alt="截屏2023-03-08 13 34 28"
src="https://user-images.githubusercontent.com/17645053/223628571-da94698b-0e0a-43e3-ae82-34d8c780e5ba.png ">
2 Right now the actions list's pagination is not working properly
because Param is not passed to pagination template, in this PR Param
Strings are passed to the pager
Before:
<img width="1176" alt="截屏2023-03-08 12 23 50"
src="https://user-images.githubusercontent.com/17645053/223629207-8b67ce74-2342-4259-bc81-036e37752716.png ">
After:
<img width="1343" alt="截屏2023-03-08 13 11 54"
src="https://user-images.githubusercontent.com/17645053/223629321-4f538f8a-45dc-4d6f-ae60-2c82680ae3e7.png ">
3 A small simplify in `RepoActionView.vue` .
---------
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com> 
						
						
					 
					
						2023-03-13 13:31:06 +08:00 
						 
				 
			
				
					
						
					 
					
						
						
							
						
						f0b0f22aed 
					 
					
						
						
							
							Add ActionRunStatus component ( #23259 )  
						
						... 
						
						
						
						Related to:
https://github.com/go-gitea/gitea/pull/23212#discussion_r1122856231 
Decrease duplication of SvgIcon when display a run status svg.
---------
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com> 
						
						
					 
					
						2023-03-06 22:35:24 +08:00 
						 
				 
			
				
					
						
					 
					
						
						
							
						
						ca84a61761 
					 
					
						
						
							
							Add run status in action view page ( #23212 )  
						
						... 
						
						
						
						Before:


After:


---------
Co-authored-by: techknowlogick <techknowlogick@gitea.io> 
						
						
					 
					
						2023-03-04 00:41:37 -05:00 
						 
				 
			
				
					
						
					 
					
						
						
							
						
						edf98a2dc3 
					 
					
						
						
							
							Require approval to run actions for fork pull request ( #22803 )  
						
						... 
						
						
						
						Currently, Gitea will run actions automatically which are triggered by
fork pull request. It's a security risk, people can create a PR and
modify the workflow yamls to execute a malicious script.
So we should require approval for first-time contributors, which is the
default strategy of a public repo on GitHub, see [Approving workflow
runs from public
forks](https://docs.github.com/en/actions/managing-workflow-runs/approving-workflow-runs-from-public-forks ).
Current strategy:
- don't need approval if it's not a fork PR;
- always need approval if the user is restricted;
- don't need approval if the user can write;
- don't need approval if the user has been approved before;
- otherwise, need approval.
https://user-images.githubusercontent.com/9418365/217207121-badf50a8-826c-4425-bef1-d82d1979bc81.mov 
GitHub has an option for that, you can see that at
`/<owner>/<repo>/settings/actions`, and we can support that later.
<img width="835" alt="image"
src="https://user-images.githubusercontent.com/9418365/217199990-2967e68b-e693-4e59-8186-ab33a1314a16.png ">
---------
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com> 
						
						
					 
					
						2023-02-24 15:58:49 +08:00 
						 
				 
			
				
					
						
					 
					
						
						
							
						
						e314c9e866 
					 
					
						
						
							
							Fix the full-height problem for all pages ( #22905 )  
						
						... 
						
						
						
						Really fix  #22883 , close  #22901 
I made a mistake that the global styles in RepoActionView.vue could
still pollute global styles (I forgot that the code of this component is
still loaded on every page, instead of loaded on demand)
This PR makes a complete fix: only change the page's full-height
behavior if the component is used.
Screenshot after the fix:
<details>

</details>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com> 
						
						
					 
					
						2023-02-14 21:04:22 +08:00 
						 
				 
			
				
					
						
					 
					
						
						
							
						
						51383ec084 
					 
					
						
						
							
							Move helpers to be prefixed with gt- ( #22879 )  
						
						... 
						
						
						
						As discussed in #22847  the helpers in helpers.less need to have a
separate prefix as they are causing conflicts with fomantic styles
This will allow us to have the `.gt-hidden { display:none !important; }`
style that is needed to for the reverted PR.
Of note in doing this I have noticed that there was already a conflict
with at least one chroma style which this PR now avoids.
I've also added in the `gt-hidden` style that matches the tailwind one
and switched the code that needed it to use that.
Signed-off-by: Andrew Thornton <art27@cantab.net>
---------
Signed-off-by: Andrew Thornton <art27@cantab.net>
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com> 
						
						
					 
					
						2023-02-13 17:59:59 +00:00 
						 
				 
			
				
					
						
					 
					
						
						
							
						
						00b18ab42f 
					 
					
						
						
							
							Remove _actions.less ( #22885 )  
						
						... 
						
						
						
						Fix  #22883 .
Revert commit 59beb2dba6b35b88dae5ac5c3d094bc6c1bba19c. 
					
						2023-02-13 08:33:33 -06:00 
						 
				 
			
				
					
						
					 
					
						
						
							
						
						a354636966 
					 
					
						
						
							
							Fix style of actions rerun button ( #22835 )  
						
						... 
						
						
						
						Authored by @a1012112796 at
https://github.com/go-gitea/gitea/pull/22798#issuecomment-1421820001 
Avoid putting `button` in `a`.
A patch for #22798  .
Now it looks like:
<img width="393" alt="image"
src="https://user-images.githubusercontent.com/9418365/217791913-b491fc86-ee9b-4672-80ea-7286eef2d11f.png ">
<img width="389" alt="image"
src="https://user-images.githubusercontent.com/9418365/217791967-d8c09c8b-4cea-4011-b01e-db0d1333e7f6.png ">
---------
Co-authored-by: silverwind <me@silverwind.io>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com> 
						
						
					 
					
						2023-02-12 19:19:50 +08:00 
						 
				 
			
				
					
						
					 
					
						
						
							
						
						7d3c4c3e8a 
					 
					
						
						
							
							Fix rerun button of Actions ( #22798 )  
						
						... 
						
						
						
						When clicking the return button, the page should be refreshed. However,
the browser may cancel the previous fetch request, and it fails to rerun
the job. It's easier to reproduce the bug in Safari or Firefox than
Chrome for some reason.
<img width="384" alt="image"
src="https://user-images.githubusercontent.com/9418365/217142792-a783f9a1-7089-44db-b7d8-46c46c72d284.png ">
<img width="752" alt="image"
src="https://user-images.githubusercontent.com/9418365/217132406-b8381b63-b323-474e-935b-2596b1b5c046.png "> 
						
						
					 
					
						2023-02-08 15:55:57 +08:00 
						 
				 
			
				
					
						
					 
					
						
						
							
						
						b6145bfaa3 
					 
					
						
						
							
							Use relative url in actions view ( #22675 )  
						
						... 
						
						
						
						Use relative url in actions view. 
						
						
					 
					
						2023-01-31 22:46:10 +00:00 
						 
				 
			
				
					
						
					 
					
						
						
							
						
						4011821c94 
					 
					
						
						
							
							Implement actions ( #21937 )  
						
						... 
						
						
						
						Close  #13539 .
Co-authored by: @lunny @appleboy @fuxiaohei and others.
Related projects:
- https://gitea.com/gitea/actions-proto-def 
- https://gitea.com/gitea/actions-proto-go 
- https://gitea.com/gitea/act 
- https://gitea.com/gitea/act_runner 
### Summary
The target of this PR is to bring a basic implementation of "Actions",
an internal CI/CD system of Gitea. That means even though it has been
merged, the state of the feature is **EXPERIMENTAL**, and please note
that:
- It is disabled by default;
- It shouldn't be used in a production environment currently;
- It shouldn't be used in a public Gitea instance currently;
- Breaking changes may be made before it's stable.
**Please comment on #13539  if you have any different product design
ideas**, all decisions reached there will be adopted here. But in this
PR, we don't talk about **naming, feature-creep or alternatives**.
### ⚠️  Breaking
`gitea-actions` will become a reserved user name. If a user with the
name already exists in the database, it is recommended to rename it.
### Some important reviews
- What is `DEFAULT_ACTIONS_URL` in `app.ini` for?
  - https://github.com/go-gitea/gitea/pull/21937#discussion_r1055954954 
- Why the api for runners is not under the normal `/api/v1` prefix?
  - https://github.com/go-gitea/gitea/pull/21937#discussion_r1061173592 
- Why DBFS?
  - https://github.com/go-gitea/gitea/pull/21937#discussion_r1061301178 
- Why ignore events triggered by `gitea-actions` bot?
  - https://github.com/go-gitea/gitea/pull/21937#discussion_r1063254103 
- Why there's no permission control for actions?
  - https://github.com/go-gitea/gitea/pull/21937#discussion_r1090229868 
### What it looks like
<details>
#### Manage runners
<img width="1792" alt="image"
src="https://user-images.githubusercontent.com/9418365/205870657-c72f590e-2e08-4cd4-be7f-2e0abb299bbf.png ">
#### List runs
<img width="1792" alt="image"
src="https://user-images.githubusercontent.com/9418365/205872794-50fde990-2b45-48c1-a178-908e4ec5b627.png ">
#### View logs
<img width="1792" alt="image"
src="https://user-images.githubusercontent.com/9418365/205872501-9b7b9000-9542-4991-8f55-18ccdada77c3.png ">
</details>
### How to try it
<details>
#### 1. Start Gitea
Clone this branch and [install from
source](https://docs.gitea.io/en-us/install-from-source ).
Add additional configurations in `app.ini` to enable Actions:
```ini
[actions]
ENABLED = true
```
Start it.
If all is well, you'll see the management page of runners:
<img width="1792" alt="image"
src="https://user-images.githubusercontent.com/9418365/205877365-8e30a780-9b10-4154-b3e8-ee6c3cb35a59.png ">
#### 2. Start runner
Clone the [act_runner](https://gitea.com/gitea/act_runner ), and follow
the
[README](https://gitea.com/gitea/act_runner/src/branch/main/README.md )
to start it.
If all is well, you'll see a new runner has been added:
<img width="1792" alt="image"
src="https://user-images.githubusercontent.com/9418365/205878000-216f5937-e696-470d-b66c-8473987d91c3.png ">
#### 3. Enable actions for a repo
Create a new repo or open an existing one, check the `Actions` checkbox
in settings and submit.
<img width="1792" alt="image"
src="https://user-images.githubusercontent.com/9418365/205879705-53e09208-73c0-4b3e-a123-2dcf9aba4b9c.png ">
<img width="1792" alt="image"
src="https://user-images.githubusercontent.com/9418365/205879383-23f3d08f-1a85-41dd-a8b3-54e2ee6453e8.png ">
If all is well, you'll see a new tab "Actions":
<img width="1792" alt="image"
src="https://user-images.githubusercontent.com/9418365/205881648-a8072d8c-5803-4d76-b8a8-9b2fb49516c1.png ">
#### 4. Upload workflow files
Upload some workflow files to `.gitea/workflows/xxx.yaml`, you can
follow the [quickstart](https://docs.github.com/en/actions/quickstart )
of GitHub Actions. Yes, Gitea Actions is compatible with GitHub Actions
in most cases, you can use the same demo:
```yaml
name: GitHub Actions Demo
run-name: ${{ github.actor }} is testing out GitHub Actions 🚀 
on: [push]
jobs:
  Explore-GitHub-Actions:
    runs-on: ubuntu-latest
    steps:
      - run: echo "🎉  The job was automatically triggered by a ${{ github.event_name }} event."
      - run: echo "🐧  This job is now running on a ${{ runner.os }} server hosted by GitHub!"
      - run: echo "🔎  The name of your branch is ${{ github.ref }} and your repository is ${{ github.repository }}."
      - name: Check out repository code
        uses: actions/checkout@v3
      - run: echo "💡  The ${{ github.repository }} repository has been cloned to the runner."
      - run: echo "🖥️  The workflow is now ready to test your code on the runner."
      - name: List files in the repository
        run: |
          ls ${{ github.workspace }}
      - run: echo "🍏  This job's status is ${{ job.status }}."
```
If all is well, you'll see a new run in `Actions` tab:
<img width="1792" alt="image"
src="https://user-images.githubusercontent.com/9418365/205884473-79a874bc-171b-4aaf-acd5-0241a45c3b53.png ">
#### 5. Check the logs of jobs
Click a run and you'll see the logs:
<img width="1792" alt="image"
src="https://user-images.githubusercontent.com/9418365/205884800-994b0374-67f7-48ff-be9a-4c53f3141547.png ">
#### 6. Go on
You can try more examples in [the
documents](https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions )
of GitHub Actions, then you might find a lot of bugs.
Come on, PRs are welcome.
</details>
See also: [Feature Preview: Gitea
Actions](https://blog.gitea.io/2022/12/feature-preview-gitea-actions/ )
---------
Co-authored-by: a1012112796 <1012112796@qq.com>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: delvh <dev.lh@web.de>
Co-authored-by: ChristopherHX <christopher.homberger@web.de>
Co-authored-by: John Olheiser <john.olheiser@gmail.com> 
					
						2023-01-31 09:45:19 +08:00