Skip to content

add CDN to exports

add CDN to exports #36

Workflow file for this run

name: main
on: [push]
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [18.x]
steps:
- uses: actions/checkout@v3
- name: Build on Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v2
with:
node-version: ${{ matrix.node-version }}
- run: yarn install --frozen-lockfile
- run: yarn build
name: Build
- run: yarn test
- uses: actions/upload-artifact@v3
with:
name: build-result
path: |
.
!.git
!node_modules/*
env:
CI: true
publish:
if: github.ref == 'refs/heads/main'
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 16
- uses: actions/download-artifact@v3
with:
name: build-result
- name: Publish
run: |
jq --version
git config --global user.email $GIT_EMAIL
git config --global user.name $GIT_USERNAME
npm config set //registry.npmjs.org/:_authToken ${NPM_TOKEN}
npm version patch
npm publish
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
GIT_EMAIL: [email protected]
GIT_USERNAME: ${{ github.actor }}