Fix command constructor #77
Workflow file for this run
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: 'Build new based on the PR changes' | |
on: | |
pull_request: | |
branches: | |
- main | |
paths: | |
- "src/**" | |
- ".github/workflows/**" | |
types: | |
- closed | |
jobs: | |
release: | |
if: github.event.pull_request.merged == true | |
name: Create release | |
runs-on: ubuntu-latest | |
steps: | |
- name: 'Checkout code' | |
uses: actions/checkout@v3 | |
- name: 'Preparation for the minor release' | |
run: echo "RELEASE_INCREMENT_TYPE=patch" >> $GITHUB_ENV | |
if: ${{ contains(github.event.pull_request.labels.*.name, 'create minor release') }} | |
- name: 'Preparation for the major release' | |
run: echo 'RELEASE_INCREMENT_TYPE=minor' >> $GITHUB_ENV | |
if: ${{ contains(github.event.pull_request.labels.*.name, 'create major release') }} | |
- name: 'Create release with increment' | |
if: ${{ env.RELEASE_INCREMENT_TYPE }} | |
uses: zendesk/action-create-release@v1 | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
auto_increment_type: ${{ env.RELEASE_INCREMENT_TYPE }} | |
tag_schema: 'semantic' | |
prerelease: true |