Skip to content
This repository has been archived by the owner on Nov 18, 2021. It is now read-only.

Commit

Permalink
ci: fix dispatch workflow
Browse files Browse the repository at this point in the history
Better tested offline this time. Unfortunately, for the reasons
described in ccbfbd2, it's only possible to test this properly once it
is merged to master.

Change-Id: Iea289f46e4d4f6d6001edee36145984f0ea10f5f
Reviewed-on: https://cue-review.googlesource.com/c/cue/+/8225
Reviewed-by: CUE cueckoo <[email protected]>
Reviewed-by: Paul Jolly <[email protected]>
  • Loading branch information
myitcv committed Jan 15, 2021
1 parent ccbfbd2 commit 8c41622
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 6 deletions.
9 changes: 6 additions & 3 deletions .github/workflows/test_dispatch.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,12 @@ jobs:
}}/review'
- name: Checkout ref
run: |-
git config --global user.name cueckoo
git config --global user.email [email protected]
mkdir tmpgit
cd tmpgit
git init
git config user.name cueckoo
git config user.email [email protected]
git config http.https://github.com/.extraheader "AUTHORIZATION: basic $(echo -n cueckoo:${{ secrets.CUECKOO_GITHUB_PAT }} | base64)"
git fetch https://cue-review.googlesource.com/cue ${{ github.event.client_payload.ref }}
git checkout -b ci/${{ github.event.client_payload.changeID }}/${{ github.event.client_payload.commit }} FETCH_HEAD
git push origin ci/${{ github.event.client_payload.changeID }}/${{ github.event.client_payload.commit }}
git push https://github.com/cuelang/cue ci/${{ github.event.client_payload.changeID }}/${{ github.event.client_payload.commit }}
9 changes: 6 additions & 3 deletions internal/ci/workflows.cue
Original file line number Diff line number Diff line change
Expand Up @@ -156,12 +156,15 @@ test_dispatch: _#bashWorkflow & {
_#step & {
name: "Checkout ref"
run: """
git config --global user.name cueckoo
git config --global user.email [email protected]
mkdir tmpgit
cd tmpgit
git init
git config user.name cueckoo
git config user.email [email protected]
git config http.https://github.com/.extraheader "AUTHORIZATION: basic $(echo -n cueckoo:${{ secrets.CUECKOO_GITHUB_PAT }} | base64)"
git fetch https://cue-review.googlesource.com/cue ${{ github.event.client_payload.ref }}
git checkout -b ci/${{ github.event.client_payload.changeID }}/${{ github.event.client_payload.commit }} FETCH_HEAD
git push origin ci/${{ github.event.client_payload.changeID }}/${{ github.event.client_payload.commit }}
git push https://github.com/cuelang/cue ci/${{ github.event.client_payload.changeID }}/${{ github.event.client_payload.commit }}
"""
},
]
Expand Down

0 comments on commit 8c41622

Please sign in to comment.