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

Removed excessive processing on the fork helper job #6504

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 2 additions & 15 deletions .github/workflows/forked-helper.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,23 +13,10 @@ jobs:
if: ${{ github.repository_owner != 'armbian' }}
runs-on: ubuntu-latest
steps:
- name: Assign secret
id: get_dispatch_secret
run: echo 'name=dispatch_secret::${{ secrets.ARMBIAN_SELF_DISPATCH_TOKEN }}' >> $GITHUB_OUTPUT
- name: Get event details
id: get_event_details
# Process JSON according https://github.com/orgs/community/discussions/26288
run: |
JSON=$(cat ${{ github.event_path }})
JSON="${JSON//'%'/'%25'}"
JSON="${JSON//$'\n'/'%0A'}"
JSON="${JSON//$'\r'/'%0D'}"
echo "name=event_details::${JSON}" >> $GITHUB_OUTPUT
- name: Dispatch event on forked repostitory
if: steps.get_dispatch_secret.outputs.dispatch_secret
uses: peter-evans/repository-dispatch@v3
with:
token: ${{ steps.get_dispatch_secret.outputs.dispatch_secret }}
token: ${{ secrets.ARMBIAN_SELF_DISPATCH_TOKEN }}
repository: ${{ github.repository }}
event-type: armbian
client-payload: >
Expand All @@ -38,5 +25,5 @@ jobs:
"ref": "${{ github.ref }}",
"base_ref": "${{ github.base_ref }}",
"sha": "${{ github.sha }}",
"event_details": ${{ steps.get_event_details.outputs.event_details }}
"event_details": ${{ toJson(github.event) }}
}