Skip to content

Commit

Permalink
chore(action): reusable tag
Browse files Browse the repository at this point in the history
  • Loading branch information
vhemery committed Mar 13, 2024
1 parent 4ef429a commit 0cc0393
Showing 1 changed file with 47 additions and 0 deletions.
47 changes: 47 additions & 0 deletions .github/workflows/_reusable_tag.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
name: Create Tag

on:
workflow_call:
inputs:
version:
type: string
description: 'Bonita technical version (e.g. 10.1.0.beta-01)'
required: true
brandingVersion:
type: string
description: 'Bonita branding version (e.g. 2024.2-b1)'
required: true
secrets:
BONITA_CI_PAT:
required: true

jobs:
create_tag:
runs-on: ubuntu-22.04
steps:
- name: Checkout
uses: actions/checkout@v4
with:
ref: ${{ github.ref }}
repository: bonitasoft/bonita-project
token: ${{ secrets.BONITA_CI_PAT }}
- name: Setup Java
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: 11
- name: Git Setup
uses: bonitasoft/git-setup-action@v1
with:
keeper-secret-config: ${{ secrets.KSM_CONFIG }}
- name: Update version
run: |
git checkout -B release/${{ inputs.version }}
./mvnw --no-transfer-progress -f parent versions:set-property -Dproperty=bonita.runtime.version -DnewVersion=${{ inputs.version }}
./mvnw --no-transfer-progress -f parent versions:set-property -Dproperty=branding.version -DnewVersion=${{ inputs.brandingVersion }}
./mvnw --no-transfer-progress versions:set -DnewVersion=${{ inputs.version }}
- name: Create tag
run: |
git commit -a -m "chore(release): Release ${{ inputs.brandingVersion }} (${{ inputs.version }})"
git tag -a ${{ inputs.version }} -m "Release ${{ inputs.brandingVersion }} (${{ inputs.version }})"
git push origin ${{ inputs.version }}:${{ inputs.version }}

0 comments on commit 0cc0393

Please sign in to comment.