Skip to content

Merge pull request #1 from tyro/release-pipeline #1

Merge pull request #1 from tyro/release-pipeline

Merge pull request #1 from tyro/release-pipeline #1

Workflow file for this run

name: Bump Version
on:
workflow_dispatch:
inputs:
bump-mode:
description: 'Select bump mode'
required: true
default: 'patch'
type: choice
options:
- patch
- minor
- major
push:
branches: [master]
jobs:
bump-version:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: Check out repository code
uses: actions/checkout@v4
- name: Setup JDK 11
uses: actions/setup-java@v3
with:
java-version: '11'
distribution: 'corretto'
- name: Setup Gradle
uses: gradle/actions/setup-gradle@417ae3ccd767c252f5661f1ace9f835f9654f2b5 # v3.1.0
- name: Retrieve New Version
run: bash ./.ci_steps/bump.sh ${{inputs.bump-mode}}
id: bump
- name: 'Checkout version-bump branch'
run: |
git fetch origin version-bump
git checkout version-bump
- name: Print Current Branch
run: echo "$(git branch --show-current)"
- name: Update Version to version-bump Branch
run: bash ./.ci_steps/update-version.sh ${{steps.bump.outputs.OLD_VERSION}} ${{steps.bump.outputs.NEW_VERSION}}
id: update
- name: Print Bump Results
run: |
echo "New Version: ${{steps.update.outputs.CURRENT_VERSION}}"