Files
tekton/.github/workflows/deploy_patch.yml
T
2026-04-22 04:21:00 +08:00

61 lines
1.8 KiB
YAML

name: Build and Release Patch PCK
on:
push:
branches:
- 'patch-release'
paths:
- 'scripts/**'
- 'scenes/**'
- 'assets/**'
- 'assets/data/version.json'
jobs:
build-and-deploy-patch:
runs-on: ubuntu-latest
steps:
- name: Checkout Source Code
uses: actions/checkout@v4
with:
fetch-depth: 2
- name: Generate Changed Files List
run: |
git diff --name-only HEAD^ HEAD > changed_files.txt
echo "Files to patch:"
cat changed_files.txt
- name: Setup Godot
uses: chickensoft-games/setup-godot@v1
with:
version: '4.2.1'
use-dotnet: false
- name: Run Build Patch Script
run: godot --headless -s tools/build_patch.gd
# Push the patch files directly to the public repository structure!
- name: Push to Public Repository
uses: dmnemec/copy_file_to_another_repo_action@main
env:
API_TOKEN_GITHUB: ${{ secrets.PUBLIC_REPO_PAT }}
with:
source_file: 'patch.pck'
destination_repo: '${{ github.actor }}/tekton-updates'
destination_folder: 'latest'
user_email: 'action@github.com'
user_name: 'PatchBot'
commit_message: '[AUTO] Pushed new patch.pck via CI'
- name: Push Version Manifest to Public Repository
uses: dmnemec/copy_file_to_another_repo_action@main
env:
API_TOKEN_GITHUB: ${{ secrets.PUBLIC_REPO_PAT }}
with:
source_file: 'assets/data/version.json'
destination_repo: '${{ github.actor }}/tekton-updates'
destination_folder: 'latest'
user_email: 'action@github.com'
user_name: 'PatchBot'
commit_message: '[AUTO] Pushed new version.json via CI'