Files
GiteaMailTemplates/.github/workflows/release.yml
T
KenanZhuandClaude 2f27d54251 docs: add Gitea version compatibility matrix and badge
- Create COMPATIBILITY.md with version matrix, Gitea release tracking,
  template variable reference, and compatibility verification process
- Add Gitea 1.25+ | 1.26.4 tested badge to README
- Update all 6 READMEs (EN + 5 translations) with latest tested version
  and link to COMPATIBILITY.md
- Include COMPATIBILITY.md in release artifacts

Co-Authored-By: Claude <noreply@anthropic.com>
2026-06-23 10:19:34 +08:00

48 lines
1.1 KiB
YAML

name: Release
on:
push:
branches: [main]
tags: ['v*']
jobs:
validate:
name: Validate Templates
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: '1.21'
- name: Lint — render all templates
working-directory: tools
run: go run . preview all
package:
name: Package & Release
if: startsWith(github.ref, 'refs/tags/v')
needs: validate
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Package themes/
run: |
VERSION=${GITHUB_REF#refs/tags/}
ARCHIVE="gitea-mail-templates-${VERSION}"
mkdir -p dist
cp -r themes LICENSE README.md COMPATIBILITY.md "dist/${ARCHIVE}"
cd dist
zip -r "${ARCHIVE}.zip" "${ARCHIVE}"
tar -czf "${ARCHIVE}.tar.gz" "${ARCHIVE}"
- name: Create Release
uses: softprops/action-gh-release@v2
with:
files: dist/*.zip,dist/*.tar.gz
generate_release_notes: true
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}