Skip to content

Merge pull request #2732 from exadel-inc/tech/esl-footnotes-clnp #13

Merge pull request #2732 from exadel-inc/tech/esl-footnotes-clnp

Merge pull request #2732 from exadel-inc/tech/esl-footnotes-clnp #13

name: Release PR Beta
on:
push:
branches: [ main-beta ]
permissions:
contents: write
pull-requests: write
env:
node-version: 20.x
jobs:
release-pr:
name: Release Please
runs-on: ubuntu-latest
steps:
- uses: google-github-actions/release-please-action@v4
id: ReleasePR
with:
default-branch: main-beta
package-name: '@exadel/esl'
versioning-strategy: default
release-type: node
command: release-pr
prerelease: true
changelog-types: '[
{"type":"feat", "section":"Features", "hidden":false},
{"type":"fix", "section":"Bug Fixes", "hidden":false},
{"type":"refactor", "section":"Refactoring", "hidden":false}
]'
pull-request-title-pattern: 'chore${scope}: release ${component} v${version}'
labels: 'release: processed'
release-labels: 'released'
# The logic below handles the npm publication:
- if: ${{ steps.ReleasePR.outputs.release_created }}
uses: actions/checkout@v4
with:
persist-credentials: false
- if: ${{ steps.ReleasePR.outputs.release_created }}
name: Use Node v${{ env.node-version }}
uses: actions/setup-node@v4
with:
cache: 'npm'
node-version: ${{ env.node-version }}
- if: ${{ steps.ReleasePR.outputs.release_created }}
name: Install NPM Dependencies
run: npm ci
- if: ${{ steps.ReleasePR.outputs.release_created }}
run: npm pack
- if: ${{ steps.ReleasePR.outputs.release_created }}
name: Upload Release Artifact
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run:
gh release upload ${{ steps.ReleasePR.outputs.tag_name }} ./exadel-esl-${{steps.ReleasePR.outputs.major}}.${{steps.ReleasePR.outputs.minor}}.${{steps.ReleasePR.outputs.patch}}.tgz
# - if: ${{ steps.ReleasePR.outputs.release_created }}
# name: Provide NPM Token
# run: npm config set //registry.npmjs.org/:_authToken $NPM_TOKEN
# env:
# NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
#
# - if: ${{ steps.ReleasePR.outputs.release_created }}
# run: npm publish
# env:
# NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}AAl@n