Skip to content

add unit test & build & publish actions #18

add unit test & build & publish actions

add unit test & build & publish actions #18

Workflow file for this run

name: build
on:
pull_request:
workflow_dispatch:
jobs:
build-and-upload-artifact:
runs-on: ubuntu-latest
env:
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
permissions:
contents: read
packages: read
steps:
- name: Checkout 🛎️
uses: actions/checkout@v3
with:
token: ${{ secrets.SSH_KEY }}
persist-credentials: false
- name: Setup 🛠️
uses: ./.github/actions/setup
- name: Build 🔧
run: |
npm set "//registry.npmjs.org/:_authToken" ${{ secrets.SSH_KEY }}
pnpm install
pnpm run lint
pnpm run test
pnpm run build
MY_PATH=$(ls packages/rtc/dist | awk -F/ '{print $NF}')
echo "::set-output name=dist_path::${MY_PATH}"
- name: Upload Artifact ⬆️
uses: actions/upload-artifact@v3
with:
name: iris-web-rtc
path: ${{steps.dist.outputs.dist_path}}