1
0
mirror of https://github.com/lensapp/lens.git synced 2025-05-20 05:10:56 +00:00
lens/.github/workflows/publish-master-npm.yml
Janne Savolainen e2733082ef
Switch to using npm over yarn
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
2023-02-06 09:25:46 +02:00

39 lines
1.0 KiB
YAML

name: Publish NPM Package `master`
on:
pull_request:
types:
- closed
concurrency:
group: publish-master-npm
cancel-in-progress: true
jobs:
publish:
name: Publish Extensions NPM Package `master`
runs-on: ubuntu-latest
if: ${{ github.event.pull_request.merged == true && contains(github.event.pull_request.labels.*.name, 'area/extension') }}
strategy:
matrix:
node-version: [16.x]
steps:
- name: Checkout Release
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Using Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
- name: Generate NPM packages
run: |
npm ci
npm run build
- name: Publish NPM package
run: |
npm config set '//registry.npmjs.org/:_authToken' "${NPM_TOKEN}"
npx lerna publish from-package --dist-tag master --no-push --no-git-tag-version --yes
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}