From a968d095c5fbca7a7d57b5e9ae9f5f26404df5a6 Mon Sep 17 00:00:00 2001 From: Natsu Date: Thu, 20 Mar 2025 21:15:43 +0700 Subject: [PATCH] feat: Update versioning and release date format This commit updates the versioning and release date format in the `check.yml` workflow. The version string now includes the datetime, branch, and short hash. The release date format has also been updated to include the time. This provides more granular information for releases. --- .github/workflows/check.yml | 19 ++++++++++++------- 1 file changed, 12 insertions(+), 7 deletions(-) diff --git a/.github/workflows/check.yml b/.github/workflows/check.yml index 2ad4f8a0..798c0e59 100644 --- a/.github/workflows/check.yml +++ b/.github/workflows/check.yml @@ -1,6 +1,13 @@ name: Check -on: [push, pull_request, workflow_dispatch] +on: + push: + branches: + - '**' + tags-ignore: + - '**' + pull_request: + workflow_dispatch: jobs: validate: @@ -104,10 +111,10 @@ jobs: run: | branch=$(git rev-parse --abbrev-ref HEAD) hash=$(git rev-parse --short=7 HEAD) - date=$(date +'%Y%m%d') - echo "$branch.$hash.$date" > version.txt - echo "VERSION=$branch.$hash.$date" >> $GITHUB_ENV - echo "RELEASE_DATE=$(date +'%Y-%m-%d')" >> $GITHUB_ENV + datetime=$(date +'%Y%m%d.%H%M%S') + echo "$datetime.$branch.$hash" > version.txt + echo "VERSION=$datetime.$branch.$hash" >> $GITHUB_ENV + echo "RELEASE_DATE=$(date +'%Y-%m-%d %H:%M:%S')" >> $GITHUB_ENV - name: Create ZIP Archive run: | @@ -119,8 +126,6 @@ jobs: tag_name: ${{ env.VERSION }} name: Translation Update ${{ env.RELEASE_DATE }} body: | - Version: ${{ env.VERSION }} - This is an automated release of the latest translation data. files: | Gakumas-Translation-Data-EN-${{ env.VERSION }}.zip