Release CI - Remove JIRA and Prefix (#8815)
This commit is contained in:
20
.github/workflows/branch_cut.yml
vendored
20
.github/workflows/branch_cut.yml
vendored
@@ -11,16 +11,6 @@ on:
|
||||
description: App Version Name (e.g., 3.0.1)
|
||||
required: true
|
||||
type: string
|
||||
jira_issue:
|
||||
description: Jira Issue ID (e.g., TP-12345)
|
||||
required: true
|
||||
default: 'TP-00000'
|
||||
type: string
|
||||
branch_prefix:
|
||||
description: Branch Prefix (e.g., release-)
|
||||
required: true
|
||||
default: 'release-'
|
||||
type: string
|
||||
|
||||
jobs:
|
||||
branch-cut:
|
||||
@@ -36,13 +26,13 @@ jobs:
|
||||
export GITHUB_EMAIL=$(echo "$GITHUB_ACTOR@navi.com" | sed 's/-/./g' | sed 's/_navi//g')
|
||||
git config --global user.email "$GITHUB_EMAIL"
|
||||
git config --global user.name "$GITHUB_ACTOR"
|
||||
- name: Checkout ${{ github.event.inputs.branch_prefix }}${{ github.event.inputs.version_name }} from ${{ github.ref_name }}
|
||||
run: git checkout -b ${{ github.event.inputs.branch_prefix }}${{ github.event.inputs.version_name }}
|
||||
- name: Checkout release-${{ github.event.inputs.version_name }} from ${{ github.ref_name }}
|
||||
run: git checkout -b release-${{ github.event.inputs.version_name }}
|
||||
- name: Update Version Name (${{ github.event.inputs.version_name }}) & Version Code (${{ github.event.inputs.version_code }})
|
||||
run: |
|
||||
sed -i 's/def VERSION_NAME = "[0-9].*"/def VERSION_NAME = "${{ github.event.inputs.version_name }}"/g' app/build.gradle
|
||||
sed -i 's/def VERSION_CODE = [0-9].*/def VERSION_CODE = ${{ github.event.inputs.version_code }}/g' app/build.gradle
|
||||
- name: Commit Version Changes
|
||||
run: git commit app/build.gradle -m "${{ github.event.inputs.jira_issue }} | Bump Project Version to ${{ github.event.inputs.version_name }} (${{ github.event.inputs.version_code }})"
|
||||
- name: Push ${{ github.event.inputs.branch_prefix }}${{ github.event.inputs.version_name }} Branch
|
||||
run: git push -u origin ${{ github.event.inputs.branch_prefix }}${{ github.event.inputs.version_name }}
|
||||
run: git commit app/build.gradle -m "Bump Project Version to ${{ github.event.inputs.version_name }} (${{ github.event.inputs.version_code }})"
|
||||
- name: Push release-${{ github.event.inputs.version_name }} Branch
|
||||
run: git push -u origin release-${{ github.event.inputs.version_name }}
|
||||
|
||||
Reference in New Issue
Block a user