diff --git a/.gitea/workflows/publish.yml b/.gitea/workflows/publish.yml new file mode 100644 index 0000000..964f3f1 --- /dev/null +++ b/.gitea/workflows/publish.yml @@ -0,0 +1,32 @@ +name: publish + +# Publish this omp port package to the npm registry on version tags. +# +# Prerequisites: +# - npm automation token (publish scope) stored as the repo secret NPM_TOKEN +# - package name claimed on npm (@mikefreno/omp-) +# +# Manual publish: Actions tab → Run workflow (workflow_dispatch). + +on: + push: + tags: ['v*'] + workflow_dispatch: + +jobs: + publish: + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Setup node (npm registry auth) + uses: actions/setup-node@v4 + with: + node-version: '22' + registry-url: 'https://registry.npmjs.org' + + - name: Publish + env: + NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} + run: npm publish --access public --ignore-scripts