Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
  • Loading branch information
Sangjun-man committed Sep 16, 2023
1 parent 2e8b84f commit d1ce2ed
Showing 1 changed file with 28 additions and 0 deletions.
28 changes: 28 additions & 0 deletions .github/workflows/repostiory_dispatch.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: Dispatch to Forked Repository

on:
push:
branches-ignore:
- '.*\/ignore-action$'

jobs:
print:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Get the refs
run: echo "[log] ref is ${{github.ref}}"
- name: Get the branch name
run: echo "[log] Branch name is ${{github.ref_name}}"

dispatch:
runs-on: ubuntu-latest
steps:
- name: Repository Dispatch
run: |
curl -L \
-X POST https://api.github.com/repos/${{vars.DEPLOY_REPO_PATH}}/dispatches \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer ${{ secrets.DEPLOY_REPO_ACCESS_TOKEN}}" \
-d '{"event_type": "sync", "client_payload": {"target_branch": "${{github.ref_name}}"}}'

0 comments on commit d1ce2ed

Please sign in to comment.