-
Notifications
You must be signed in to change notification settings - Fork 65
33 lines (29 loc) · 891 Bytes
/
sdk.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
name: Generate SDK
on:
push:
jobs:
generate-sdk:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 'lts/iron'
cache: 'yarn'
- run: yarn install --immutable
- name: Generate SDK
run: yarn generate-sdk
- name: Push to repository
env:
GITHUB_TOKEN: ${{ secrets.TEST_PERSONAL_ACCESS_TOKEN_FOR_SDK_GEN }}
REPO_NAME: cgw-sdk
run: |
git config --global user.name 'iamacook'
git config --global user.email '[email protected]'
git clone [email protected]:5afe/cgw-sdk.git cloned-repo
mkdir -p cloned-repo/dist
cp -r dist/sdk/* cloned-repo/dist/
cd cloned-repo
git add .
git commit -m "Update SDK according to ${{ github.sha }}"
git push