mirror of
https://github.com/arthurfiorette/axios-cache-interceptor.git
synced 2025-12-08 17:36:16 +00:00
36 lines
738 B
YAML
36 lines
738 B
YAML
name: Publish to NPM
|
|
|
|
on:
|
|
release:
|
|
types: [published]
|
|
workflow_dispatch:
|
|
|
|
jobs:
|
|
publish:
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v2
|
|
with:
|
|
ref: ${{ github.head_ref }}
|
|
fetch-depth: 0
|
|
|
|
- name: Setup node and restore cached dependencies
|
|
uses: actions/setup-node@v2
|
|
with:
|
|
node-version: '16'
|
|
registry-url: 'https://registry.npmjs.org/'
|
|
cache: 'yarn'
|
|
|
|
- name: Install packages
|
|
run: yarn --prefer-offline
|
|
|
|
- name: Build
|
|
run: npm run build
|
|
|
|
- name: Publish to NPM
|
|
run: npm publish --access public
|
|
env:
|
|
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
|