-
Notifications
You must be signed in to change notification settings - Fork 0
37 lines (35 loc) · 1.1 KB
/
update-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
34
35
36
37
name: Update SDK Submodule (swift)
on:
workflow_call:
workflow_dispatch:
push:
branches:
- main
pull_request:
paths:
- ".github/workflows/update-sdk.yml"
jobs:
update_sdk_submodule:
name: Update SDK Submodule
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
repository: 'trinsic-id/sdk'
ref: 'main'
path: 'sdk'
submodules: recursive
token: ${{ secrets.SDK_REPO_PUSH_TOKEN }}
- name: Update the submodule
run: |
git config user.name github-actions
git config user.email [email protected]
git checkout -b "update-sdk-swift"
git submodule update --remote
git add .
git commit -m "Updated SDK Swift Submodule"
git push --force --set-upstream origin "update-sdk-swift"
echo ${{ secrets.SDK_REPO_PUSH_TOKEN }} | gh auth login --with-token
gh pr create --base main --title "Update SDK Swift Submodule" --body "Update SDK Swift Submodule"
working-directory: ./sdk