Merge branch 'main' of github.com:exadel-inc/esl into main-beta #9
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: Release PR Beta | |
on: | |
push: | |
branches: [ main-beta ] | |
permissions: | |
contents: write | |
pull-requests: write | |
env: | |
node-version: 18.x | |
jobs: | |
release-pr: | |
name: Release Please | |
runs-on: ubuntu-latest | |
steps: | |
- uses: google-github-actions/release-please-action@v3 | |
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@v3 | |
with: | |
persist-credentials: false | |
- if: ${{ steps.ReleasePR.outputs.release_created }} | |
name: Use Node v${{ env.node-version }} | |
uses: actions/setup-node@v3 | |
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 | |