Skip to content

Bump org.apache.maven.plugins:maven-jar-plugin from 3.3.0 to 3.4.1 #342

Bump org.apache.maven.plugins:maven-jar-plugin from 3.3.0 to 3.4.1

Bump org.apache.maven.plugins:maven-jar-plugin from 3.3.0 to 3.4.1 #342

Workflow file for this run

# SPDX-License-Identifier: Apache-2.0 OR MIT
#
# SPDX-FileCopyrightText: Copyright 2022 Micron Technology, Inc.
name: Builds
on:
release:
types: [created]
push:
branches:
- master
- "v[0-9]+.[0-9]+"
paths:
- "**.c"
- "**.h"
- "**.java"
- "**/meson.build"
- "subprojects/*.wrap"
- "cross/*.ini"
- .github/workflows/builds.yaml
- meson_options.txt
- pom.xml
- VERSION
pull_request:
types: [opened, synchronize, reopened]
paths:
- "**.c"
- "**.h"
- "**.java"
- "**/meson.build"
- "subprojects/*.wrap"
- "cross/*.ini"
- .github/workflows/builds.yaml
- meson_options.txt
- pom.xml
- VERSION
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref }}
cancel-in-progress: true
permissions:
packages: read
env:
MESON_TESTTHREADS: 1
jobs:
determine-tag:
runs-on: ubuntu-latest
continue-on-error: false
outputs:
tag: ${{ steps.determine-tag.outputs.tag }}
steps:
- name: Determine tag
id: determine-tag
run: |
if [ "$GITHUB_EVENT_NAME" = "pull_request" ]; then
echo "tag=$GITHUB_BASE_REF" >> "$GITHUB_OUTPUT"
else
echo "tag=$GITHUB_REF_NAME" >> "$GITHUB_OUTPUT"
fi
normal:
runs-on: ubuntu-latest
needs:
- determine-tag
container:
image: ghcr.io/hse-project/ci-images/${{ matrix.image }}:${{ needs.determine-tag.outputs.tag }}
strategy:
fail-fast: false
matrix:
image:
- almalinux-8
- almalinux-9
- cross-s390x
- fedora-37
- ubuntu-18.04
- ubuntu-20.04
- ubuntu-22.04
buildtype: [release, debug]
steps:
- name: To skip or not to skip
id: to-skip
shell: sh +e {0}
run: |
skip="false"
echo "${{ matrix.image }}" | grep -P --quiet "(almalinux-8|almalinux-9|ubuntu-20.04|ubuntu-22.04)"
if [ $? -eq 0 ] && [ "$GITHUB_EVENT_NAME" != "release" ]; then
skip="true"
fi
echo "skip=$skip" >> "$GITHUB_OUTPUT"
- name: Checkout hse-java
if: ${{ steps.to-skip.outputs.skip == 'false' }}
uses: actions/checkout@v3
- name: Determine branches
id: determine-branches
if: ${{ steps.to-skip.outputs.skip == 'false' }}
shell: sh +e {0}
run: |
for p in hse; do
branch=master
if [ "$GITHUB_EVENT_NAME" = "pull_request" ]; then
git ls-remote --exit-code --heads \
"https://github.com/hse-project/$p.git" "$GITHUB_HEAD_REF" \
> /dev/null
if [ $? -eq 0 ]; then
branch="$GITHUB_HEAD_REF"
fi
elif [ "$GITHUB_EVENT_NAME" = "release" ]; then
branch="$GITHUB_REF_NAME"
else
git ls-remote --exit-code --heads \
"https://github.com/hse-project/$p.git" "$GITHUB_REF" \
> /dev/null
if [ $? -eq 0 ]; then
branch="$GITHUB_REF_NAME"
fi
fi
echo "$p=$branch" >> "$GITHUB_OUTPUT"
done
- name: Checkout HSE
if: ${{ steps.to-skip.outputs.skip == 'false' }}
uses: actions/checkout@v3
with:
repository: hse-project/hse
path: subprojects/hse
ref: ${{ steps.determine-branches.outputs.hse }}
- name: Export Maven local repository
id: maven-local-repository
if: ${{ steps.to-skip.outputs.skip == 'false' }}
run: |
local_repository=$(mvn help:evaluate -Dexpression=settings.localRepository --quiet -DforceStdout)
echo "local-repository=$local_repository" >> "$GITHUB_OUTPUT"
- name: Cache Maven dependencies
id: maven-dependencies
if: ${{ steps.to-skip.outputs.skip == 'false' }}
uses: actions/cache@v3
with:
path: ${{ steps.maven-local-repository.outputs.local-repository }}
key: maven-dependencies-${{ hashFiles('pom.xml') }}
# Download all dependencies up front if cache wasn't hit. Will keep
# Maven from downloading dependencies during the test phase which could
# cause tests to timeout.
- name: Download Maven dependencies
if: ${{ steps.to-skip.outputs.skip == 'false' && steps.maven-dependencies.outputs.cache-hit != 'true' }}
run: |
mvn dependency:go-offline
- name: Cache Meson packagecache
if: ${{ steps.to-skip.outputs.skip == 'false' }}
id: meson-packagecache
uses: actions/cache@v3
with:
path: subprojects/packagecache
key: meson-packagecache-${{ matrix.image }}-${{ hashFiles('subprojects/hse/subprojects/*.wrap') }}
- name: Export cross arguments
if: ${{ steps.to-skip.outputs.skip == 'false' && startsWith(matrix.image, 'cross') }}
run: |
image="${{ matrix.image }}"
echo "CROSS_ARGS=--cross-file cross/${image##*-}.ini --cross-file cross/common.ini" >> "$GITHUB_ENV"
- name: Setup
if: ${{ steps.to-skip.outputs.skip == 'false' }}
run: |
MESON_ARGS=
if [ "${{ matrix.image }}" = "ubuntu-18.04" ]; then
# javadoc is not available on Ubuntu 18.04
MESON_ARGS="-Ddocs=false"
fi
meson setup builddir --fatal-meson-warnings $MESON_ARGS \
--buildtype=${{ matrix.buildtype }} $CROSS_ARGS --werror
- name: Build
if: ${{ steps.to-skip.outputs.skip == 'false' }}
run: |
DOCS_TARGET=
if [ "${{ matrix.image }}" != "ubuntu-18.04" ]; then
# javadoc is not available on Ubuntu 18.04
DOCS_TARGET="docs/apidocs"
fi
ninja -C builddir all $DOCS_TARGET
- name: Test
if: ${{ steps.to-skip.outputs.skip == 'false' && !startsWith(matrix.image, 'cross') }}
run: |
meson test -C builddir --setup=ci --print-errorlogs --no-stdsplit
- uses: actions/upload-artifact@v4
if: failure()
with:
name: ${{ matrix.image }}-${{ matrix.buildtype }}
path: builddir/meson-logs/