Skip to content

v13.0.0

v13.0.0 #36

name: Publish Typescript to NPM
on:
workflow_dispatch:
release:
types: [created]
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Setup Node
uses: actions/setup-node@v2
with:
node-version: '20.x'
registry-url: 'https://registry.npmjs.org'
- name: Install buf
run: |
curl -sSL https://github.com/bufbuild/buf/releases/download/v1.28.1/buf-Linux-x86_64 -o /usr/local/bin/buf
chmod +x /usr/local/bin/buf
- name: Generate
run: |
make typescript
- name: Set Version
working-directory: typescript
run: |
version=$(cat ../app/setup_handlers.go | grep "const releaseVersion" | cut -d ' ' -f4 | tr -d '"')
npm version ${version}
- name: Publish package on NPM 📦
run: npm publish
working-directory: typescript
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}