Skip to content

Add script to install Xerces in local M2 on Windows too #57

Add script to install Xerces in local M2 on Windows too

Add script to install Xerces in local M2 on Windows too #57

Workflow file for this run

name: Build
on:
push:
branches:
- main
pull_request:
branches:
- main
create:
tags:
- "*"
repository_dispatch:
types:
- build
jobs:
build:
name: Build
runs-on: ubuntu-latest
env:
MAVEN_OPTS: -Dorg.slf4j.simpleLogger.log.org.apache.maven.cli.transfer.Slf4jMavenTransferListener=warn
steps:
- name: Check new version
if: github.event_name == 'create' && github.event.ref_type == 'tag'
id: check-tag
run: |
tagName="${GITHUB_REF#refs/tags/}"
if printf '%s' "$tagName" | grep -Eq '^[0-9]+\.[0-9]+\.[0-9]+$'; then
echo "tag=$tagName" >>"$GITHUB_OUTPUT"
fi
-
name: Checkout
uses: actions/checkout@v3
-
name: Set up JDK 17
uses: actions/setup-java@v3
with:
java-version: '17'
distribution: temurin
cache: maven
-
name: Install Xerces with XSD 1.1 support in local M2 repository
run: ./bin/install-xerces-m2.sh
-
name: Update version
if: steps.check-tag.outputs.tag
run: mvn --batch-mode -Dstyle.color=always org.eclipse.tycho:tycho-versions-plugin:set-version "-DnewVersion=${{ steps.check-tag.outputs.tag }}"
-
name: Compile
run: mvn --batch-mode -Dstyle.color=always compile
-
name: Verify
run: mvn --batch-mode -Dstyle.color=always verify
-
name: Print version
run: java -jar concrete-cif.jar --version
-
name: Copy jar to temporary folder
run: cp concrete-cif.jar /tmp/
-
name: Test good CIFs with jar
run: cd /tmp && java -jar concrete-cif.jar "$GITHUB_WORKSPACE/src/test/resources/cifs-good"
-
name: Test bad CIFs with jar
run: cd /tmp && ! java -jar concrete-cif.jar "$GITHUB_WORKSPACE/src/test/resources/cifs-bad"
-
name: Calculate hash
if: steps.check-tag.outputs.tag
run: sha1sum concrete-cif.jar | tee -a concrete-cif.jar.sha1
-
name: Create release
if: steps.check-tag.outputs.tag
uses: marvinpinto/action-automatic-releases@latest
with:
repo_token: "${{ secrets.GITHUB_TOKEN }}"
prerelease: false
files: |
concrete-cif.jar
concrete-cif.jar.sha1
src/main/resources/concrete-cif-1.0.xsd