Skip to content

build: bump the govuk group across 1 directory with 6 updates #2325

build: bump the govuk group across 1 directory with 6 updates

build: bump the govuk group across 1 directory with 6 updates #2325

name: Publish packages
on:
workflow_run:
workflows: [Bump version]
types: [completed]
pull_request:
types:
- opened
- reopened
- synchronize
env:
WORKFLOW_OUT_DIR: ./workflow-outputs
jobs:
publish-packages:
name: ${{ github.event_name == 'pull_request' && 'Test publishing packages' || 'Publish packages' }}
env:
JDK_VERSION: 21
GITHUB_ACTOR: ${{ secrets.MODULE_FETCH_TOKEN_USERNAME}}
GITHUB_TOKEN: ${{ secrets.MODULE_FETCH_TOKEN }}
permissions:
packages: write
runs-on: ubuntu-latest
steps:
- name: Run checkout github action
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
ref: ${{ github.event_name == 'workflow_run' && github.event.workflow_run.head_sha || '' }}
lfs: 'true'
submodules: 'true'
fetch-depth: 0
- name: Read bump-version outputs
if: ${{ github.event_name == 'workflow_run' && github.event.workflow_run.conclusion == 'success' }}
id: bump-version
uses: ./actions/read-bump-version-outputs
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
workflow-out-dir: ${{ env.WORKFLOW_OUT_DIR }}
workflow-run-id: ${{ github.event.workflow_run.id }}
- name: Setup GitHub Runner workflow
uses: ./mobile-android-pipelines/actions/setup-runner
with:
jdk-version: 21
- name: Cache mobile-android-pipelines build
uses: ./actions/cache-pipelines-build
- name: Publish to Github Packages
if: ${{ github.event_name == 'workflow_run' && steps.bump-version.outputs.version-bumped == 'true' }}
uses: ./mobile-android-pipelines/actions/maven-publish
with:
GITHUB_ACTOR: ${{ secrets.MODULE_PUSH_TOKEN_USERNAME }}
GITHUB_TOKEN: ${{ secrets.MODULE_PUSH_TOKEN }}
VERSION_NAME: ${{ steps.bump-version.outputs.new-version }}
- name: Test publishing to Maven local
if: ${{ github.event_name == 'pull_request' }}
uses: ./mobile-android-pipelines/actions/maven-publish-local
with:
expected-packages: '
uk.gov.onelogin.criorchestrator.features:resume-internal,
uk.gov.onelogin.criorchestrator.features:resume-internal-api,
uk.gov.onelogin.criorchestrator.features:resume-public-api,
uk.gov.onelogin.criorchestrator.features:select-doc-internal,
uk.gov.onelogin.criorchestrator.features:select-doc-internal-api,
uk.gov.onelogin.criorchestrator.libraries:analytics,
uk.gov.onelogin.criorchestrator.libraries:di,
uk.gov.onelogin.criorchestrator.libraries:screenshot-testing,
uk.gov.onelogin.criorchestrator.sdk:sdk,
uk.gov.onelogin.criorchestrator.sdk:sdk-internal,
uk.gov.onelogin.criorchestrator.sdk:sdk-shared-api'
version-name: ${{ steps.bump-version.outputs.new-version }}
- name: Clean workspace
uses: ./mobile-android-pipelines/actions/clean-workspace