From 67f487bc68d072153baebcd2fdc829aa84788378 Mon Sep 17 00:00:00 2001 From: Nick Cross Date: Thu, 12 Mar 2026 08:27:42 +0000 Subject: [PATCH] Add GH Actions --- .github/workflows/maven-pr.yml | 17 +++++++++++++++++ .github/workflows/maven-release.yml | 19 +++++++++++++++++++ .github/workflows/maven-snapshot.yml | 12 ++++++++++++ 3 files changed, 48 insertions(+) create mode 100644 .github/workflows/maven-pr.yml create mode 100644 .github/workflows/maven-release.yml create mode 100644 .github/workflows/maven-snapshot.yml diff --git a/.github/workflows/maven-pr.yml b/.github/workflows/maven-pr.yml new file mode 100644 index 000000000..a72079497 --- /dev/null +++ b/.github/workflows/maven-pr.yml @@ -0,0 +1,17 @@ +# This workflow will build a Java project with Maven, and cache/restore any dependencies to improve the workflow execution time +# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-java-with-maven + +# This workflow uses actions that are not certified by GitHub. +# They are provided by a third-party and are governed by +# separate terms of service, privacy policy, and support +# documentation. + +name: Java CI with Maven + +on: + pull_request: + branches: [ "*" ] + +jobs: + call-maven-ci: + uses: project-ncl/shared-github-actions/.github/workflows/maven-ci.yml@v0.0.12 diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml new file mode 100644 index 000000000..bbe13f4f7 --- /dev/null +++ b/.github/workflows/maven-release.yml @@ -0,0 +1,19 @@ +name: "0 Central Release Job" # Adding the 0 so that it's on top of the list of github actions +on: + workflow_dispatch: # Manual trigger so you don't release on every push + inputs: + ref_to_release: + description: '[Optional] Branch or commit to release. Default: Github default branch' + required: false + type: string + # default has to be a static string, no variables allowed + default: '' + +jobs: + call-release-job: + permissions: + contents: write # needed to push commit and tag back to the repository + uses: project-ncl/shared-github-actions/.github/workflows/maven-release.yml@v0.0.12 + with: + ref_to_release: ${{ inputs.ref_to_release }} + secrets: inherit diff --git a/.github/workflows/maven-snapshot.yml b/.github/workflows/maven-snapshot.yml new file mode 100644 index 000000000..75e6d3fdc --- /dev/null +++ b/.github/workflows/maven-snapshot.yml @@ -0,0 +1,12 @@ +name: Build snapshot version and upload to Maven Central + +on: + push: + branches: [ "main" ] + +jobs: + call-snapshot-job: + uses: project-ncl/shared-github-actions/.github/workflows/maven-snapshot.yml@v0.0.12 + with: + project_name: 'project-ncl/reqour' + secrets: inherit