Files
RSSHub/.github/workflows/npm-publish.yml
T
dependabot[bot] 9f791abda7 chore(deps): bump actions/setup-node from 3.0.0 to 3.1.0 (#9445)
Bumps [actions/setup-node](https://github.com/actions/setup-node) from 3.0.0 to 3.1.0.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](https://github.com/actions/setup-node/compare/v3.0.0...v3.1.0)

---
updated-dependencies:
- dependency-name: actions/setup-node
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-04-02 06:05:02 +08:00

31 lines
750 B
YAML

name: publish
on:
push:
branches:
- master
paths:
- 'lib/**'
jobs:
build:
name: npm publish
if: github.repository == 'DIYgod/RSSHub'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3.1.0
with:
node-version: '14'
cache: 'yarn'
registry-url: 'https://registry.npmjs.org'
- name: Release
run: |
git config --local user.email "action@github.com"
git config --local user.name "GitHub Action"
npx version-from-git --allow-same-version --template 'master.short'
- name: Publish to npmjs
run: npm publish
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}