Skip to content

Update Versions

Update Versions #15

# This is a basic workflow that is manually triggered
# IMPORTANT!
# For this repo which contains AEPCore, AEPIdentity, AEPLifecycle, AEPServices, and AEPSignal, it is assumed
# that when the version is updated for AEPCore, all other extensions (excluding AEPServices) will also
# have their minimum dependencies updated to the same new version.
name: Update Versions
# Controls when the action will run. Workflow runs when manually triggered using the UI
# or API.
on:
workflow_dispatch:
# Inputs the workflow accepts.
inputs:
version:
description: 'New version to use for the extension. Example: 3.0.2'
required: true
branch:
description: 'Branch to be used when updating versions'
required: true
rules-engine-dependency:
description: 'If a version is provided, update AEPRulesEngine dependency in podspec and Package.swift'
required: false
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
update-versions:
runs-on: macos-latest
# Steps represent a sequence of tasks that will be executed as part of the job
steps:
- name: Checkout
uses: actions/[email protected]
with:
ref: ${{ github.event.inputs.branch }}
- if: ${{ github.event.inputs.rules-engine-dependency != '' }}
name: Update AEPCore
run: (sh ./Script/update-versions.sh -n Core -v ${{ github.event.inputs.version }} -d "AEPRulesEngine ${{ github.event.inputs.rules-engine-dependency }}, AEPServices ${{ github.event.inputs.version }}")
- if: ${{ github.event.inputs.rules-engine-dependency == '' }}
name: Update AEPCore (no update to Rules Engine dependency)
run: (sh ./Script/update-versions.sh -n Core -v ${{ github.event.inputs.version }} -d "AEPServices ${{ github.event.inputs.version }}")
- name: Update AEPIdentity
run: (sh ./Script/update-versions.sh -n Identity -v ${{ github.event.inputs.version }} -d "AEPCore ${{ github.event.inputs.version }}")
- name: Update AEPLifecycle
run: (sh ./Script/update-versions.sh -n Lifecycle -v ${{ github.event.inputs.version }} -d "AEPCore ${{ github.event.inputs.version }}")
- name: Update AEPServices
run: (sh ./Script/update-versions.sh -n Services -v ${{ github.event.inputs.version }})
- name: Update AEPSignal
run: (sh ./Script/update-versions.sh -n Signal -v ${{ github.event.inputs.version }} -d "AEPCore ${{ github.event.inputs.version }}")
- name: Create Pull Request
uses: peter-evans/[email protected]
with:
token: ${{ github.token }}
commit-message: Updating versions to ${{ github.event.inputs.version }}.
branch: version-${{ github.event.inputs.version }}-update
delete-branch: true
title: Updating versions to ${{ github.event.inputs.version }}
body: Updating versions to ${{ github.event.inputs.version }}