Skip to content

chore: minor debug

chore: minor debug #9

Workflow file for this run

name: Publish nopalm to npm registry
on:
push:
branches:
- main
jobs:
versioning:
runs-on: ubuntu-latest
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
steps:
# Checkout the code
- name: Checkout code
uses: actions/checkout@v3
# Set up Node.js environment
- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: '20'
registry-url: 'https://registry.npmjs.org/'
# Install all dependencies (including devDependencies for lint/test/build)
- name: Install dependencies
run: yarn install
# Run linting
- name: Run lint
run: yarn lint
# Run tests
- name: Run tests
run: yarn test
# Build production version of react client
- name: Build client
run: yarn build-client
# Verify NPM_TOKEN
- name: Verify NPM_TOKEN
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
run: |
echo "NPM_TOKEN: $NPM_TOKEN"
echo "secrets.NPM_TOKEN: ${{ secrets.NPM_TOKEN }}"
curl -H "Authorization: Bearer ${{ secrets.NPM_TOKEN }}" https://registry.npmjs.org/-/whoami
# Semantic release step: Automatically determine the version and release
- name: Semantic Release for versioning
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
run: yarn release
publish:
needs: versioning
runs-on: ubuntu-latest
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Install production dependencies
run: yarn install --frozen-lockfile --production
# Publish to npm
- name: Publish to npm
run: yarn publish --non-interactive
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}