0
0
Fork 0
mirror of https://codeberg.org/forgejo/docs.git synced 2024-11-21 17:36:59 -05:00

user: actions: clarify pull_request_target will checkout the base

This commit is contained in:
Earl Warren 2023-11-08 16:14:21 +01:00
parent fcb6347c18
commit 7cf8b2fc95
No known key found for this signature in database
GPG key ID: 0579CB2928A78A00

View file

@ -356,9 +356,11 @@ are not available and the automatic token only has read permissions.
It is similar to the `on.pull_request` event, with the following exceptions:
- the `workflow` found in the target (base) branch of the pull request
is used instead of the one found in the pull request.
- secrets are available.
- secrets stored in the base repository are available in the `secrets` context, (e.g. `${{ secrets.KEY }}`).
- the workflow runs in the context of the default branch of the base repository, meaning that:
- changes to the workflow in the pull request will be ignored
- the [actions/checkout](https://code.forgejo.org/actions/checkout) action will checkout the default branch instead
of the content of the pull request
[Check out the example](https://code.forgejo.org/forgejo/end-to-end/src/branch/main/actions/example-pull-request/.forgejo/workflows/test.yml).