@@ -139,48 +139,48 @@ jobs:
139139
140140 - name : run anchor tests
141141 run : bash test-scripts/run-anchor-tests.sh
142- check-for-sdk-changes :
143- runs-on : ubuntu-latest
144- # Set job outputs to values from filter step
145- outputs :
146- sdk : ${{ steps.filter.outputs.sdk }}
147- steps :
148- # For pull requests it's not necessary to checkout the code
149- - uses : actions/checkout@v2
150- - uses : dorny/paths-filter@v2
151- id : filter
152- with :
153- filters : |
154- sdk:
155- - 'sdk/src/**'
156- release :
157- runs-on : ubuntu-latest
158- needs : [fmt-clippy, unit, cargo-audit, yarn-prettier, yarn-lint, anchor-tests, check-for-sdk-changes]
159- if : ${{ github.ref == 'refs/heads/master' && needs.check-for-sdk-changes.outputs.sdk == 'true' }}
160- defaults :
161- run :
162- working-directory : ./sdk
163- steps :
164- - uses : actions/checkout@v2
165- - name : Setup node
166- uses : actions/setup-node@v2
167- with :
168- node-version : ' 16.x'
169- registry-url : ' https://registry.npmjs.org'
170- - name : Build sdk
171- run : yarn
172- - run : yarn build
173- - name : Update package version
174- run : npm version prerelease --preid=beta
175- - name : Git commit
176- run : |
177- VERSION=$(node -e "console.log(require('./package.json').version);")
178- git config user.name "GitHub Actions"
179- git config user.email 41898282+github-actions[bot]@users.noreply.github.com
180- git add ..
181- git commit -a -m "sdk: release v$VERSION"
182- git push origin HEAD
183- - name : Publish to npm
184- run : npm publish --access=public
185- env :
186- NODE_AUTH_TOKEN : ${{ secrets.NPM_TOKEN }}
142+ check-for-sdk-changes :
143+ runs-on : ubuntu-latest
144+ # Set job outputs to values from filter step
145+ outputs :
146+ sdk : ${{ steps.filter.outputs.sdk }}
147+ steps :
148+ # For pull requests it's not necessary to checkout the code
149+ - uses : actions/checkout@v2
150+ - uses : dorny/paths-filter@v2
151+ id : filter
152+ with :
153+ filters : |
154+ sdk:
155+ - 'sdk/src/**'
156+ release :
157+ runs-on : ubuntu-latest
158+ needs : [fmt-clippy, unit, cargo-audit, yarn-prettier, yarn-lint, anchor-tests, check-for-sdk-changes]
159+ if : ${{ github.ref == 'refs/heads/master' && needs.check-for-sdk-changes.outputs.sdk == 'true' }}
160+ defaults :
161+ run :
162+ working-directory : ./sdk
163+ steps :
164+ - uses : actions/checkout@v2
165+ - name : Setup node
166+ uses : actions/setup-node@v2
167+ with :
168+ node-version : ' 16.x'
169+ registry-url : ' https://registry.npmjs.org'
170+ - name : Build sdk
171+ run : yarn
172+ - run : yarn build
173+ - name : Update package version
174+ run : npm version prerelease --preid=beta
175+ - name : Git commit
176+ run : |
177+ VERSION=$(node -e "console.log(require('./package.json').version);")
178+ git config user.name "GitHub Actions"
179+ git config user.email 41898282+github-actions[bot]@users.noreply.github.com
180+ git add ..
181+ git commit -a -m "sdk: release v$VERSION"
182+ git push origin HEAD
183+ - name : Publish to npm
184+ run : npm publish --access=public
185+ env :
186+ NODE_AUTH_TOKEN : ${{ secrets.NPM_TOKEN }}
0 commit comments