feat: add Linux build to build.yml, mirror releases to tekton-updates
This commit is contained in:
+36
-49
@@ -33,7 +33,6 @@ jobs:
|
||||
mkdir -p "$TEMPLATES_DIR"
|
||||
wget -q https://github.com/godotengine/godot/releases/download/4.6-stable/Godot_v4.6-stable_export_templates.tpz -O templates.tpz
|
||||
unzip -q templates.tpz -d "$TEMPLATES_DIR"
|
||||
# tpz extracts into templates/ subfolder — flatten it
|
||||
mv "$TEMPLATES_DIR/templates/"* "$TEMPLATES_DIR/"
|
||||
rmdir "$TEMPLATES_DIR/templates"
|
||||
|
||||
@@ -49,7 +48,7 @@ jobs:
|
||||
path: build/tekton_armageddon_windows.exe
|
||||
retention-days: 30
|
||||
|
||||
build-android:
|
||||
build-linux:
|
||||
runs-on: ubuntu-latest
|
||||
permissions:
|
||||
contents: write
|
||||
@@ -73,65 +72,30 @@ jobs:
|
||||
mv "$TEMPLATES_DIR/templates/"* "$TEMPLATES_DIR/"
|
||||
rmdir "$TEMPLATES_DIR/templates"
|
||||
|
||||
- name: Setup Android SDK
|
||||
uses: android-actions/setup-android@v3
|
||||
|
||||
- name: Export Android Build
|
||||
- name: Export Linux Build
|
||||
run: |
|
||||
mkdir -p build
|
||||
godot --headless --export-release "Android" build/tekton_armageddon_android.apk
|
||||
godot --headless --export-release "Linux/X11" build/tekton_armageddon_linux.x86_64
|
||||
|
||||
- name: Upload Android Artifact
|
||||
- name: Upload Linux Artifact
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: android-build
|
||||
path: build/tekton_armageddon_android.apk
|
||||
retention-days: 30
|
||||
|
||||
build-macos:
|
||||
runs-on: macos-latest
|
||||
permissions:
|
||||
contents: write
|
||||
|
||||
steps:
|
||||
- name: Checkout Source Code
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Setup Godot
|
||||
uses: chickensoft-games/setup-godot@v1
|
||||
with:
|
||||
version: '4.6.0'
|
||||
use-dotnet: false
|
||||
|
||||
- name: Setup Export Templates
|
||||
run: |
|
||||
TEMPLATES_DIR=~/Library/Application\ Support/Godot/export_templates/4.6.stable
|
||||
mkdir -p "$TEMPLATES_DIR"
|
||||
wget -q https://github.com/godotengine/godot/releases/download/4.6-stable/Godot_v4.6-stable_export_templates.tpz -O templates.tpz
|
||||
unzip -q templates.tpz -d "$TEMPLATES_DIR"
|
||||
mv "$TEMPLATES_DIR/templates/"* "$TEMPLATES_DIR/"
|
||||
rmdir "$TEMPLATES_DIR/templates"
|
||||
|
||||
- name: Export macOS Build
|
||||
run: |
|
||||
mkdir -p build
|
||||
godot --headless --export-release "macOS" build/tekton_armageddon_macos.zip
|
||||
|
||||
- name: Upload macOS Artifact
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: macos-build
|
||||
path: build/tekton_armageddon_macos.zip
|
||||
name: linux-build
|
||||
path: build/tekton_armageddon_linux.x86_64
|
||||
retention-days: 30
|
||||
|
||||
create-release:
|
||||
needs: [build-windows]
|
||||
needs: [build-windows, build-linux]
|
||||
runs-on: ubuntu-latest
|
||||
if: always() && startsWith(github.ref, 'refs/tags/')
|
||||
permissions:
|
||||
contents: write
|
||||
|
||||
steps:
|
||||
- name: Extract Version
|
||||
id: version
|
||||
run: echo "version=${GITHUB_REF#refs/tags/v}" >> $GITHUB_OUTPUT
|
||||
|
||||
- name: Download All Artifacts
|
||||
uses: actions/download-artifact@v4
|
||||
|
||||
@@ -140,9 +104,32 @@ jobs:
|
||||
with:
|
||||
files: |
|
||||
windows-build/tekton_armageddon_windows.exe
|
||||
android-build/tekton_armageddon_android.apk
|
||||
macos-build/tekton_armageddon_macos.zip
|
||||
linux-build/tekton_armageddon_linux.x86_64
|
||||
draft: false
|
||||
prerelease: false
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
- name: Mirror Windows to tekton-updates
|
||||
uses: dmnemec/copy_file_to_another_repo_action@main
|
||||
env:
|
||||
API_TOKEN_GITHUB: ${{ secrets.PUBLIC_REPO_PAT }}
|
||||
with:
|
||||
source_file: 'windows-build/tekton_armageddon_windows.exe'
|
||||
destination_repo: '${{ github.actor }}/tekton-updates'
|
||||
destination_folder: 'v${{ steps.version.outputs.version }}'
|
||||
user_email: 'action@github.com'
|
||||
user_name: 'ReleaseBot'
|
||||
commit_message: '[AUTO] Mirror v${{ steps.version.outputs.version }} Windows build'
|
||||
|
||||
- name: Mirror Linux to tekton-updates
|
||||
uses: dmnemec/copy_file_to_another_repo_action@main
|
||||
env:
|
||||
API_TOKEN_GITHUB: ${{ secrets.PUBLIC_REPO_PAT }}
|
||||
with:
|
||||
source_file: 'linux-build/tekton_armageddon_linux.x86_64'
|
||||
destination_repo: '${{ github.actor }}/tekton-updates'
|
||||
destination_folder: 'v${{ steps.version.outputs.version }}'
|
||||
user_email: 'action@github.com'
|
||||
user_name: 'ReleaseBot'
|
||||
commit_message: '[AUTO] Mirror v${{ steps.version.outputs.version }} Linux build'
|
||||
|
||||
Reference in New Issue
Block a user