Update npm-publish.yml #4
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Major Release | |
on: | |
push: | |
branches: | |
- master | |
env: | |
REGISTRY: ghcr.io | |
IMAGE_NAME: ${{ github.repository }} | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
permissions: | |
contents: write | |
packages: write | |
steps: | |
- name: Checkout repo | |
uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
- name: Get previous tag | |
id: previoustag | |
uses: 'WyriHaximus/github-action-get-previous-tag@v1' | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
fallback: 1.0.0 | |
- name: Get next minor version | |
id: semver | |
uses: 'WyriHaximus/github-action-next-semvers@v1' | |
with: | |
version: ${{ steps.previoustag.outputs.tag }} | |
- name: Generate changelog | |
id: changelog | |
uses: TriPSs/conventional-changelog-action@v3 | |
with: | |
github-token: ${{ secrets.GITHUB_TOKEN }} | |
create-summary: true | |
skip-on-empty: 'false' | |
skip-commit: 'false' | |
- name: Create release | |
id: create_release_id | |
uses: actions/create-release@v1 | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
tag_name: ${{ steps.semver.outputs.patch }} | |
release_name: Release ${{ steps.semver.outputs.patch }} | |
body: ${{ steps.changelog.outputs.clean_changelog }} |