diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 215bfabb9..f1f4f852a 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -19,4 +19,9 @@ jobs: java-version: '17' distribution: 'temurin' - name: Build and validate project - run: mvn -B package --file pom.xml \ No newline at end of file + run: | + if [ -z "$(find modules -mindepth 2 -maxdepth 2 -name pom.xml 2>/dev/null)" ]; then + echo "No plugin modules present under modules/; skipping build/validate (see test-generation workflow for scaffold validation)." + exit 0 + fi + mvn -B package --file pom.xml \ No newline at end of file diff --git a/.github/workflows/test-generation.yml b/.github/workflows/test-generation.yml index bb7c55b2a..c1794c069 100644 --- a/.github/workflows/test-generation.yml +++ b/.github/workflows/test-generation.yml @@ -2,11 +2,15 @@ name: test-generation # Integration test for the plugin generation process (gephi-maven-plugin's # generate/validate/build-metadata/create-autoupdate goals). Runs on every -# master commit so a version bump of gephi-maven-plugin in pom.xml is -# regression-tested before real plugin repos pick it up. +# master commit and on PRs targeting master (master has no plugin modules of +# its own, so build.yml's build_and_test can't validate scaffold changes) so +# a version bump of gephi-maven-plugin in pom.xml is regression-tested before +# real plugin repos pick it up. on: push: branches: [ master ] + pull_request: + branches: [ master ] jobs: generation-integration-test: