Skip to content

Merge pull request #1 from ZettaScaleLabs/main #1

Merge pull request #1 from ZettaScaleLabs/main

Merge pull request #1 from ZettaScaleLabs/main #1

Workflow file for this run

name: Package zenoh-ts
on:
workflow_dispatch:
inputs:
publish:
description: 'Publish artifacts'
default: false
required: false
type: boolean
version:
description: 'Library version'
required: false
default: '0.0.1'
type: string
zenoh_version:
description: 'Zenoh version'
required: true
type: string
default: '1.0.0-alpha.6'
push:
defaults:
run:
shell: bash
working-directory: ./zenoh-ts
jobs:
package:
name: Package app for ${{ matrix.job.name }}
env:
NUXT_PUBLIC_VERSION: ${{ inputs.version }}
strategy:
fail-fast: false
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
steps:
- name: Checkout
uses: actions/checkout@v4
- name: git config
run: |
git config --global user.name "${GITHUB_ACTOR}"
git config --global user.email "${GITHUB_ACTOR}@users.noreply.github.com"
- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: 20
registry-url: https://npm.pkg.github.com/
- name: Run install
uses: borales/actions-yarn@v4
with:
cmd: install
dir: ./zenoh-ts
- name: Transpile Code
run: yarn run build
- name: Publish
id: publish
shell: bash
env:
YARN_NPM_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NODE_AUTH_TOKEN: ${{secrets.GITHUB_TOKEN}}
run: |
npm install
npx release-it
- name: Cleanup
if: always()
run: |
rm -rf node_modules
rm -rf dist
rm -rf package-lock.json