Skip to content

Docs: 2.2.16 Version.270.func. #92

Docs: 2.2.16 Version.270.func.

Docs: 2.2.16 Version.270.func. #92

Workflow file for this run

name: npm package js-xxx CI/CD
on:
push:
branches: [publish]
paths:
- 'src/**'
jobs:
publish:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
- name: Cache node_modules
uses: actions/cache@v2
env:
cache-name: cache-node-modules
with:
path: ~/.npm
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-build-${{ env.cache-name }}-
${{ runner.os }}-build-
${{ runner.os }}-
- name: Init Node.js
run: |
npm config set //registry.npmjs.org/:_authToken=$NPM_TOKEN
npm run pub
echo "publish..."
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
result:
runs-on: ubuntu-latest
needs: publish
steps:
- name: Result
run: |
echo "Publish Successful!"