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

pkarwasz pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/logging-log4j-transform.git

commit 98d2038453703278d97feb2d712acd0867628c64
Author: Piotr P. Karwasz <[email protected]>
AuthorDate: Tue May 2 19:13:12 2023 +0200

    Add automatic tagging
---
 .github/workflows/build.yml | 11 +++++++++++
 1 file changed, 11 insertions(+)

diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml
index 7d317fa..0273d4c 100644
--- a/.github/workflows/build.yml
+++ b/.github/workflows/build.yml
@@ -195,3 +195,14 @@ jobs:
         with:
           name: Sources
           path: target/apache-log4j-transform-*-src.zip*
+          if-no-file-found: error
+
+      - name: Tag version (RELEASE)
+        if: startsWith(github.ref, 'refs/heads/release/')
+        run: |
+          export RCN=$[ $(git tag -l "rel/$PROJECT_VERSION[-.]rc*" | wc -l) + 
1 ]
+          export TAG="rel/$PROJECT_VERSION-rc$RCN"
+          git config user.name github-actions
+          git config user.email [email protected]
+          git tag "$TAG" -m ""
+          git push origin "$TAG"

Reply via email to