actions: use FORGEJO_* instead of GITHUB_* and test backward compatibility (#758)
Refs forgejo/act#171 Refs actions/setup-forgejo#461 Reviewed-on: https://code.forgejo.org/forgejo/end-to-end/pulls/758 Reviewed-by: Michael Kriese <michael.kriese@gmx.de> Co-authored-by: Earl Warren <contact@earl-warren.org> Co-committed-by: Earl Warren <contact@earl-warren.org>
This commit is contained in:
parent
f0eadf960b
commit
49c2072cbe
2 changed files with 140 additions and 116 deletions
|
|
@ -6,20 +6,22 @@ inputs:
|
|||
runs:
|
||||
using: "composite"
|
||||
steps:
|
||||
- name: GITHUB_ACTION_REPOSITORY
|
||||
- name: FORGEJO_ACTION_REPOSITORY
|
||||
run: |
|
||||
set -x
|
||||
test "$GITHUB_ACTION_REPOSITORY" = root/action-for-context
|
||||
test "$GITHUB_ACTION_REPOSITORY" = "${{ env.GITHUB_ACTION_REPOSITORY }}"
|
||||
test "$GITHUB_ACTION_REPOSITORY" = "${{ github.ACTION_REPOSITORY }}"
|
||||
test "$GITHUB_ACTION_REPOSITORY" = "${{ forge.ACTION_REPOSITORY }}"
|
||||
touch /srv/example/example-context/GITHUB_ACTION_REPOSITORY
|
||||
test "$FORGEJO_ACTION_REPOSITORY" = root/action-for-context
|
||||
test "$FORGEJO_ACTION_REPOSITORY" = "${{ env.FORGEJO_ACTION_REPOSITORY }}"
|
||||
test "$FORGEJO_ACTION_REPOSITORY" = "${{ github.ACTION_REPOSITORY }}"
|
||||
test "$FORGEJO_ACTION_REPOSITORY" = "${{ forge.ACTION_REPOSITORY }}"
|
||||
test "$FORGEJO_ACTION_REPOSITORY" = "$GITHUB_ACTION_REPOSITORY"
|
||||
touch /srv/example/example-context/FORGEJO_ACTION_REPOSITORY
|
||||
|
||||
- name: GITHUB_ACTION_PATH
|
||||
- name: FORGEJO_ACTION_PATH
|
||||
shell: bash
|
||||
run: |
|
||||
set -x
|
||||
[[ "$GITHUB_ACTION_PATH" =~ action-for-context@main$ ]]
|
||||
test "$GITHUB_ACTION_PATH" = "${{ github.ACTION_PATH }}"
|
||||
test "$GITHUB_ACTION_PATH" = "${{ forge.ACTION_PATH }}"
|
||||
touch /srv/example/example-context/GITHUB_ACTION_PATH
|
||||
[[ "$FORGEJO_ACTION_PATH" =~ action-for-context@main$ ]]
|
||||
test "$FORGEJO_ACTION_PATH" = "${{ github.ACTION_PATH }}"
|
||||
test "$FORGEJO_ACTION_PATH" = "${{ forge.ACTION_PATH }}"
|
||||
test "$FORGEJO_ACTION_PATH" = "$GITHUB_ACTION_PATH"
|
||||
touch /srv/example/example-context/FORGEJO_ACTION_PATH
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue