Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update documentation for 1.21 actions #26317

Merged
merged 3 commits into from
Aug 4, 2023

Conversation

sillyguodong
Copy link
Contributor

@sillyguodong sillyguodong commented Aug 4, 2023

As title.
Close #26309
Related to #24724, #24806

@GiteaBot GiteaBot added the lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. label Aug 4, 2023
@pull-request-size pull-request-size bot added the size/M Denotes a PR that changes 30-99 lines, ignoring generated files. label Aug 4, 2023
@sillyguodong sillyguodong added the type/docs This PR mainly updates/creates documentation label Aug 4, 2023
@GiteaBot GiteaBot added lgtm/need 1 This PR needs approval from one additional maintainer to be merged. and removed lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. labels Aug 4, 2023
@GiteaBot GiteaBot added lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. and removed lgtm/need 1 This PR needs approval from one additional maintainer to be merged. labels Aug 4, 2023
@lunny lunny added this to the 1.21.0 milestone Aug 4, 2023
@lunny lunny added the reviewed/wait-merge This pull request is part of the merge queue. It will be merged soon. label Aug 4, 2023
@lunny lunny enabled auto-merge (squash) August 4, 2023 09:05
@GiteaBot
Copy link
Contributor

GiteaBot commented Aug 4, 2023

@sillyguodong please fix the merge conflicts. 🍵

@GiteaBot GiteaBot removed the reviewed/wait-merge This pull request is part of the merge queue. It will be merged soon. label Aug 4, 2023
@lunny lunny merged commit 0da8ebc into go-gitea:main Aug 4, 2023
23 checks passed
@@ -245,8 +245,7 @@ You can find more useful images on [act images](https://github.com/nektos/act/bl
If you want to run jobs in the host directly, you can change it to `ubuntu-22.04:host` or just `ubuntu-22.04`, the `:host` is optional.
However, we suggest you to use a special name like `linux_amd64:host` or `windows:host` to avoid misusing it.

One more thing is that it is recommended to register the runner if you want to change the labels.
It may be annoying to do this, so we may provide a better way to do it in the future.
After Gitea 1.21 released, you can change labels by modfiying `container.labels` in configuration file (if you don't have a configuration file, please refer to [configuration tutorials](#configuration)), and runner will declare the new labels which you defined in configuration file after executing `./act_runner daemon --config config.yaml`.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
After Gitea 1.21 released, you can change labels by modfiying `container.labels` in configuration file (if you don't have a configuration file, please refer to [configuration tutorials](#configuration)), and runner will declare the new labels which you defined in configuration file after executing `./act_runner daemon --config config.yaml`.
Starting with Gitea 1.21, you can change labels by modifying `container.labels` in the runner configuration file (if you don't have a configuration file, please refer to [configuration tutorials](#configuration)).
The runner will use these new labels as soon as you restart it, i.e., by calling `./act_runner daemon --config config.yaml`.


## Configuration variable

You can create configuration varibales with user, organization, repository level. And the level of the variable depends on which setting panel you created in.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
You can create configuration varibales with user, organization, repository level. And the level of the variable depends on which setting panel you created in.
You can create configuration variables on the user, organization, and repository level.
The level of the variable depends on where you created it.

Comment on lines +272 to +282
- Varibale names can only contain alphanumeric characters (`[a-z]`, `[A-Z]`, `[0-9]`) or underscores (`_`). Spaces are not allowed.

- Varibale names must not start with the `GITHUB_` and `GITEA_` prefix.

- Varibale names must not start with a number.

- Varibale names are not case-sensitive.

- Varibale names must be unique at the level they are created at.

- Varibale names must not be 'CI'.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- Varibale names can only contain alphanumeric characters (`[a-z]`, `[A-Z]`, `[0-9]`) or underscores (`_`). Spaces are not allowed.
- Varibale names must not start with the `GITHUB_` and `GITEA_` prefix.
- Varibale names must not start with a number.
- Varibale names are not case-sensitive.
- Varibale names must be unique at the level they are created at.
- Varibale names must not be 'CI'.
- Variable names can only contain alphanumeric characters (`[a-z]`, `[A-Z]`, `[0-9]`) or underscores (`_`). Spaces are not allowed.
- Variable names must not start with the `GITHUB_` and `GITEA_` prefix.
- Variable names must not start with a number.
- Variable names are case-insensitive.
- Variable names must be unique at the level they are created at.
- Variable names must not be `CI`.


### Using varibales

After creating configuration varibales, they will be automatically filled in the `vars` context. They are available to you with expression like `{{ vars.VARIABLE_NAME }}` in workflow.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
After creating configuration varibales, they will be automatically filled in the `vars` context. They are available to you with expression like `{{ vars.VARIABLE_NAME }}` in workflow.
After creating configuration variables, they will be automatically filled in the `vars` context. They can be accessed through expressions like `{{ vars.VARIABLE_NAME }}` in the workflow.

Comment on lines +290 to +291
If a variable with the same name exists at multiple levels, the variable at the lowest level takes precedence(the level of organization and user is higher than repository's).
For example, if an organization-level variable has the same name as a repository-level variable, then the repository-level variable takes precedence.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
If a variable with the same name exists at multiple levels, the variable at the lowest level takes precedence(the level of organization and user is higher than repository's).
For example, if an organization-level variable has the same name as a repository-level variable, then the repository-level variable takes precedence.
If a variable with the same name exists at multiple levels, the variable at the lowest level takes precedence:
A repository variable will always be chosen over an organization/user variable.

@GiteaBot GiteaBot added lgtm/blocked A maintainer has reservations with the PR and thus it cannot be merged and removed lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. labels Aug 4, 2023
@delvh
Copy link
Member

delvh commented Aug 4, 2023

Oh.

@sillyguodong
Copy link
Contributor Author

I will create a new PR to update😂

lunny pushed a commit that referenced this pull request Aug 4, 2023
follow #26317
fix typos and adjust grammer problems.
zjjhot added a commit to zjjhot/gitea that referenced this pull request Aug 6, 2023
* upstream/main: (25 commits)
  [docs] Add missing backtick in quickstart.zh-cn.md (go-gitea#26349)
  Fix incorrect CLI exit code and duplicate error message (go-gitea#26346)
  Improve CLI and messages (go-gitea#26341)
  Remove backslashed newlines on markdown (go-gitea#26344)
  Hide `last indexed SHA` when a repo could not be indexed yet (go-gitea#26340)
  Fix log typo in task.go (go-gitea#26337)
  Prevent newline errors with Debian packages (go-gitea#26332)
  Fix the bug when getting files changed for `pull_request_target` event (go-gitea#26320)
  Refactor backend SVG package and add tests (go-gitea#26335)
  Fix bug with sqlite load read (go-gitea#26305)
  Remove commit load branches and tags in wiki repo (go-gitea#26304)
  Add highlight to selected repos in milestone dashboard (go-gitea#26300)
  Do not show Profile README when repository is private (go-gitea#26295)
  Fix incorrect color of selected assignees when create issue (go-gitea#26324)
  Delete `issue_service.CreateComment` (go-gitea#26298)
  Make git batch operations use parent context timeout instead of default timeout (go-gitea#26325)
  Fix typos and grammer problems for actions documentation (go-gitea#26328)
  Update documentation for 1.21 actions (go-gitea#26317)
  Fix the wrong derive path (go-gitea#26271)
  Support getting changed files when commit ID is `EmptySHA` (go-gitea#26290)
  ...
@go-gitea go-gitea locked as resolved and limited conversation to collaborators Nov 2, 2023
@sillyguodong sillyguodong deleted the doc/actions_1.21_feature branch February 29, 2024 03:29
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
lgtm/blocked A maintainer has reservations with the PR and thus it cannot be merged size/M Denotes a PR that changes 30-99 lines, ignoring generated files. type/docs This PR mainly updates/creates documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

"Variable" set for gitea action not accessible in job
5 participants