Skip to content

fix(hf): cd publisher #6

fix(hf): cd publisher

fix(hf): cd publisher #6

Workflow file for this run

name: Release Workflow
on:
release:
types: [created]
jobs:
publisher:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- id: get_version
run: |
VERSION=$(echo "${{ github.event.release.name }}" | sed -E 's/.*v([0-9.]+).*/\1/')
echo "version=$VERSION" >> $GITHUB_OUTPUT
- run: sed -i 's/"version":.*".*"/"version": "'${{ steps.get_version.outputs.version }}'"/' package.json

Check failure on line 16 in .github/workflows/publisher.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/publisher.yml

Invalid workflow file

You have an error in your yaml syntax on line 16
- uses: actions/setup-node@v4
with:
node-version: '20.x'
registry-url: 'https://registry.npmjs.org/'
scope: '@mathcovax'
- run: npm ci
- run: npm run build
- run: |
if [ "${{ github.event.release.prerelease }}" = "true" ]; then
npm publish --tag beta --access public
else
npm publish --access public
fi
env:
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}