Skip to content

chore(deps): update kotlin packages to v2.0.21 #630

chore(deps): update kotlin packages to v2.0.21

chore(deps): update kotlin packages to v2.0.21 #630

Workflow file for this run

name: ci
on:
push:
branches:
- "**"
defaults:
run:
# NOTE: A bit stricter than the default bash options used by GitHub Actions
# (bash --noprofile --norc -e -o pipefail {0})
shell: bash --noprofile --norc -euo pipefail {0}
# NOTE: Set concurrency for the current workflow to 1
concurrency: ci-${{ github.ref }}-${{ github.workflow }}
jobs:
build-and-release:
runs-on: ubuntu-24.04
permissions:
contents: write
packages: write
steps:
- uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871 # v4.2.1
- uses: actions/setup-java@b36c23c0d998641eff861008f374ee103c25ac73 # v4.4.0
with:
distribution: "zulu"
java-version: "11.0.22"
java-package: "jdk"
- uses: capralifecycle/actions-lib/check-runtime-dependencies@f3dcdbe2cd85725311b4ff5ff8dde9dfaf4f3111 # v1.5.4
- name: cache mvn
uses: actions/cache@3624ceb22c1c5a301c8db4169662070a689d9ea8 # v4.1.1
with:
path: ~/.m2/repository
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-maven-
- name: release preparation
id: prep
run: |
git config --global user.name "github-actions[bot]"
git config --global user.email "github-actions[bot]@users.noreply.github.com"
major_version="$(sed -n "s/^.*<major-version>\([0-9]\{1,\}\)<\/major-version>.*$/\1/p" pom.xml)"
echo "$major_version" | grep -q "^[0-9]\{1,\}$" || {
echo "ERROR: Failed to extract <major-version> from pom.xml"
exit 1
}
echo "major-version=$major_version" >> "$GITHUB_OUTPUT"
- uses: capralifecycle/actions-lib/generate-tag@f3dcdbe2cd85725311b4ff5ff8dde9dfaf4f3111 # v1.5.4
id: tag
with:
tag-prefix: "${{ steps.prep.outputs.major-version }}"
tag-type: "punctuated-timestamp-tag"
- name: resolve dependencies
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: mvn -B dependency:resolve
- name: conditional release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
CONDITIONAL_RELEASE: ${{ github.ref == format('refs/heads/{0}', github.event.repository.default_branch) }}
TAG: "${{ steps.tag.outputs.tag }}"
run: |
if [ "$CONDITIONAL_RELEASE" = "true" ]; then
echo "Releasing library with tag '$TAG'"
mvn -B source:jar deploy scm:tag -Drevision="$TAG" -Dtag="$TAG" \
org.apache.maven.plugins:maven-enforcer-plugin:3.0.0-M3:enforce -Drules=requireReleaseDeps
else
mvn -B -U verify
fi