Skip to content

Create new version

Create new version #5

name: 'Create new version'
on:
workflow_dispatch:
inputs:
minor:
description: 'Minor version number'
type: number
required: true
major:
description: 'Major version number'
type: number
required: true
permissions:
actions: read
pages: write
id-token: write
contents: write
concurrency:
group: create-new-version-${{ github.head_ref || github.ref }}
cancel-in-progress: false
jobs:
versioning:
name: 'Determine version'
runs-on: ubuntu-latest
outputs:
is-breaking-change: ${{ inputs.major > steps.versioning.outputs.major }}
steps:
- name: 'Checkout ${{ github.head_ref || github.ref }}'
uses: actions/checkout@v4
- name: 'Determine versions'
uses: ./.github/actions/determine-version
id: determine-version
with:
config-file-path: './.gitversion/version.yml'
run-number: ${{ github.run-number }}
variables:
name: 'Read variables'
runs-on: ubuntu-latest
needs: [versioning]
steps:
- name: 'Read variables'
id: set-variables
run: |
echo "major: ${{ steps.versioning.outputs.major }}"
echo "minor: ${{ steps.versioning.outputs.minor }}"
echo "is-breaking-change: ${{ steps.versioning.outputs.is-breaking-change }}"