This is an automated email from the ASF dual-hosted git repository.

ggregory pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/commons-release-plugin.git


The following commit(s) were added to refs/heads/master by this push:
     new 0f5fdc9  Run builds only on push to `master` and pull requests (#423)
0f5fdc9 is described below

commit 0f5fdc9fc352dd9b33a38e8a155d55678b1c3f76
Author: Piotr P. Karwasz <[email protected]>
AuthorDate: Fri Apr 3 12:51:08 2026 +0200

    Run builds only on push to `master` and pull requests (#423)
    
    * Run build only on `master` and PRs
    
    When a PR is created from a branch in the same repository, workflows run 
twice: once on `push` and once on `pull_request`.
    
    This change fixes it, by only running workflows:
    
    - On a direct push to `master`,
    - On a Pull Request, regardless of the origin.
    
    * fix: replace double with single quotes
    
    Replaces `"` with `'` as suggested in the review.
---
 .github/workflows/maven.yml | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/.github/workflows/maven.yml b/.github/workflows/maven.yml
index 2b3e739..6b8cd51 100644
--- a/.github/workflows/maven.yml
+++ b/.github/workflows/maven.yml
@@ -15,7 +15,11 @@
 
 name: Java CI
 
-on: [push, pull_request]
+on:
+  push:
+    branches:
+      - 'master'
+  pull_request: {}
 
 permissions:
   contents: read

Reply via email to