Skip to content

Bump dependencies

Bump dependencies #47

Workflow file for this run

name: Release SDK if needed
on:
pull_request:
branches:
- main
types:
- closed
jobs:
release:
runs-on: ubuntu-latest
if: github.event.pull_request.merged == true && contains(github.event.pull_request.head.ref, 'release/')
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: '20.x'
registry-url: 'https://registry.npmjs.org'
- run: npm install
- name: Publish to npm
run: npm publish
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
- name: Create Release tag
id: create-tag
env:
PR_REF: ${{ github.event.pull_request.head.ref }}
run: |
release_tag=$(echo "$PR_REF" | cut -d "/" -f2)
echo "::set-output name=release-tag::$release_tag"
- name: Make new release
uses: ncipollo/release-action@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
tag: ${{ steps.create-tag.outputs.release-tag }}
commit: main
body: ${{ github.event.pull_request.body }}