mirror of
https://gitea.com/gitea/runner.git
synced 2026-11-05 14:55:44 +00:00
Adds built-in actions, native Go actions shipped with the runner and selected with `uses: builtin:<name>`. Jobs need no action download and no Node in their image. The first one is `builtin:checkout`, a subset of `actions/checkout` with `repository`, `ref`, `token`, `path` and `fetch-depth`. Other inputs fail the step. The runner clones shallowly on its host and copies the tree into the job, while `gitea-runner exec` copies the local working directory for the workflow's own ref. `actions/checkout` and other remote actions are unchanged. A clone ref of `HEAD` now shallow-clones the remote's default branch, which checkout uses for other repositories. --------- Co-authored-by: silverwind <[email protected]> Co-authored-by: silverwind <[email protected]> Reviewed-on: https://gitea.com/gitea/runner/pulls/871 Reviewed-by: silverwind <[email protected]> Co-authored-by: bircni <[email protected]>
22 lines
651 B
Markdown
22 lines
651 B
Markdown
# Built-in actions
|
|
|
|
Built-in actions ship with the runner, so a job needs no action download and no Node in its image.
|
|
|
|
```yaml
|
|
- uses: builtin:checkout
|
|
```
|
|
|
|
## checkout
|
|
|
|
Works like `actions/checkout` with these inputs. Any other input fails the step.
|
|
|
|
| Input | Default |
|
|
| --- | --- |
|
|
| `repository` | `github.repository` |
|
|
| `ref` | the triggering commit, or the default branch of another repository |
|
|
| `token` | `github.token` |
|
|
| `path` | workspace root |
|
|
| `fetch-depth` | `1`, `0` for full history |
|
|
|
|
With `gitea-runner exec`, checking out the workflow's own repository copies your local working directory, unless `--no-skip-checkout` is set.
|