New Release #119
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: Create a new Release | |
on: | |
push: | |
branches: | |
- release/** | |
jobs: | |
javascript: | |
runs-on: ubuntu-latest | |
steps: | |
# Setup | |
- uses: wemogy/[email protected] | |
id: release-version | |
with: | |
token: ${{ secrets.GITHUB_TOKEN }} | |
- name: Checkout at release tag | |
uses: actions/checkout@v2 | |
- name: Setup Node.js | |
uses: actions/setup-node@v2 | |
with: | |
node-version: 12 | |
registry-url: https://registry.npmjs.org | |
# Build | |
- name: Install packages | |
run: yarn install | |
- name: Set version number | |
run: npm version ${{ steps.release-version.outputs.next-version }} --no-git-tag-version --allow-same-version | |
- name: Build application | |
run: yarn build | |
- name: Publish NPM package | |
run: npm publish | |
env: | |
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} | |
# Create GitHub Release | |
- name: Create GitHub Release | |
uses: softprops/action-gh-release@v1 | |
with: | |
tag_name: ${{ steps.release-version.outputs.next-version }} | |
name: Version ${{ steps.release-version.outputs.next-version }} | |
generate_release_notes: true | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |