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.
This commit is contained in:
2025-03-20 21:15:43 +07:00
parent a1c8f0553e
commit a968d095c5

View File

@@ -1,6 +1,13 @@
name: Check name: Check
on: [push, pull_request, workflow_dispatch] on:
push:
branches:
- '**'
tags-ignore:
- '**'
pull_request:
workflow_dispatch:
jobs: jobs:
validate: validate:
@@ -104,10 +111,10 @@ jobs:
run: | run: |
branch=$(git rev-parse --abbrev-ref HEAD) branch=$(git rev-parse --abbrev-ref HEAD)
hash=$(git rev-parse --short=7 HEAD) hash=$(git rev-parse --short=7 HEAD)
date=$(date +'%Y%m%d') datetime=$(date +'%Y%m%d.%H%M%S')
echo "$branch.$hash.$date" > version.txt echo "$datetime.$branch.$hash" > version.txt
echo "VERSION=$branch.$hash.$date" >> $GITHUB_ENV echo "VERSION=$datetime.$branch.$hash" >> $GITHUB_ENV
echo "RELEASE_DATE=$(date +'%Y-%m-%d')" >> $GITHUB_ENV echo "RELEASE_DATE=$(date +'%Y-%m-%d %H:%M:%S')" >> $GITHUB_ENV
- name: Create ZIP Archive - name: Create ZIP Archive
run: | run: |
@@ -119,8 +126,6 @@ jobs:
tag_name: ${{ env.VERSION }} tag_name: ${{ env.VERSION }}
name: Translation Update ${{ env.RELEASE_DATE }} name: Translation Update ${{ env.RELEASE_DATE }}
body: | body: |
Version: ${{ env.VERSION }}
This is an automated release of the latest translation data. This is an automated release of the latest translation data.
files: | files: |
Gakumas-Translation-Data-EN-${{ env.VERSION }}.zip Gakumas-Translation-Data-EN-${{ env.VERSION }}.zip