ScientaNL / release-npm-github-action

Release NPM Package Github Action

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

release-npm-github-action

This Github action releases a new version of an NPM package whenever a new release is done on Github.

After a Github release is made, this action will;

  • Commit to your repository, updating the package.json
  • Release a new version of an npm package using npm publish

Example configuration

name: Create release
on:
  release:
    types: [ created ]
jobs:
  npm-version-publish:
    name: NPM publish locking-cache
    runs-on: ubuntu-latest
    steps:
      - name: Checkout repository
        uses: actions/checkout@v3

      - name: NPM version release
        uses: ScientaNL/release-npm-github-action@1.2.1
        with:
          github-token: "${{ secrets.GITHUB_TOKEN }}"
          npm-token: "${{ secrets.NPM_SCIENTA_TOKEN }}"
          repository-owner: "ScientaNL"
          npm-options: "{tag: 'latest', access: 'public'}"

see https://docs.npmjs.com/cli/v6/commands/npm-publish for more information.

About

Release NPM Package Github Action

License:MIT License


Languages

Language:JavaScript 100.0%