mirror of
https://github.com/litruv/PNGTuber-Plus.git
synced 2026-07-24 02:26:02 +10:00
149 lines
5.7 KiB
YAML
149 lines
5.7 KiB
YAML
name: Build Windows
|
|
|
|
|
|
on:
|
|
push:
|
|
branches: [ master, main ]
|
|
pull_request:
|
|
branches: [ master, main ]
|
|
workflow_dispatch:
|
|
|
|
env:
|
|
GODOT_VERSION: 4.4.1
|
|
EXPORT_NAME: PNGTuber-Plus
|
|
|
|
jobs:
|
|
export-windows:
|
|
name: Windows Export
|
|
runs-on: self-hosted
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v4
|
|
with:
|
|
lfs: true
|
|
|
|
- name: Debug Environment
|
|
run: |
|
|
Write-Host "Current directory: $(Get-Location)"
|
|
Write-Host "Godot executable exists: $(Test-Path 'D:\Godot\Godot_v4.4.1-stable_win64.exe')"
|
|
Write-Host "Export name: $env:EXPORT_NAME"
|
|
Write-Host "Project file exists: $(Test-Path 'project.godot')"
|
|
Get-ChildItem -Path . -Filter "*.cfg" | Select-Object Name
|
|
|
|
- name: Setup Export Templates
|
|
run: |
|
|
Write-Host "Setting up Godot export templates..."
|
|
$templatesPath = "$env:APPDATA\Godot\export_templates\4.4.1.stable"
|
|
if (!(Test-Path $templatesPath)) {
|
|
Write-Host "Export templates not found, downloading..."
|
|
New-Item -ItemType Directory -Force -Path $templatesPath
|
|
|
|
# Download export templates
|
|
$templateUrl = "https://github.com/godotengine/godot/releases/download/4.4.1-stable/Godot_v4.4.1-stable_export_templates.tpz"
|
|
$templateFile = "$env:TEMP\export_templates.tpz"
|
|
|
|
Write-Host "Downloading from: $templateUrl"
|
|
Invoke-WebRequest -Uri $templateUrl -OutFile $templateFile
|
|
|
|
# Extract templates
|
|
Expand-Archive -Path $templateFile -DestinationPath "$env:TEMP\templates" -Force
|
|
|
|
# Copy templates to correct location
|
|
$extractedPath = "$env:TEMP\templates\templates"
|
|
if (Test-Path $extractedPath) {
|
|
Copy-Item -Path "$extractedPath\*" -Destination $templatesPath -Recurse -Force
|
|
Write-Host "Export templates installed successfully"
|
|
} else {
|
|
Write-Host "Failed to extract templates"
|
|
exit 1
|
|
}
|
|
} else {
|
|
Write-Host "Export templates already exist"
|
|
}
|
|
|
|
- name: Windows Build
|
|
run: |
|
|
New-Item -ItemType Directory -Force -Path "build\windows"
|
|
Write-Host "Starting Godot export..."
|
|
|
|
# Run Godot export with timeout
|
|
$process = Start-Process -FilePath "D:\Godot\Godot_v4.4.1-stable_win64.exe" -ArgumentList "--headless", "--verbose", "--export-release", "Windows Desktop", "build\windows\PNGTuber-Plus.exe" -PassThru -Wait -NoNewWindow
|
|
|
|
Write-Host "Godot exit code: $($process.ExitCode)"
|
|
|
|
Write-Host "Checking if export file exists..."
|
|
if (Test-Path "build\windows\PNGTuber-Plus.exe") {
|
|
Write-Host "Export successful! File size: $((Get-Item 'build\windows\PNGTuber-Plus.exe').Length) bytes"
|
|
} else {
|
|
Write-Host "Export failed - no executable found"
|
|
Write-Host "Checking default export location..."
|
|
if (Test-Path ".export") {
|
|
Get-ChildItem -Path ".export" -Recurse | Select-Object FullName, Length
|
|
}
|
|
Write-Host "Checking templates directory..."
|
|
$templatesPath = "$env:APPDATA\Godot\export_templates\4.4.1.stable"
|
|
if (Test-Path $templatesPath) {
|
|
Get-ChildItem -Path $templatesPath | Select-Object Name
|
|
}
|
|
exit 1
|
|
}
|
|
continue-on-error: false
|
|
|
|
- name: Check Build Output
|
|
run: |
|
|
Write-Host "Build directory contents:"
|
|
Get-ChildItem -Path "build\windows" -Recurse | Select-Object Name, Length
|
|
|
|
- name: Upload Windows Build
|
|
uses: actions/upload-artifact@v4
|
|
with:
|
|
name: windows-build
|
|
path: build/windows/
|
|
retention-days: 14
|
|
|
|
release:
|
|
name: Create Release
|
|
needs: export-windows
|
|
runs-on: self-hosted
|
|
if: github.ref == 'refs/heads/master' && github.event_name == 'push' && success()
|
|
steps:
|
|
- name: Download Windows Build
|
|
uses: actions/download-artifact@v4
|
|
with:
|
|
name: windows-build
|
|
path: ./windows/
|
|
|
|
- name: Create Release
|
|
id: create_release
|
|
uses: actions/create-release@v1
|
|
env:
|
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
with:
|
|
tag_name: build-${{ github.sha }}
|
|
release_name: PNGTuber Plus Build ${{ github.sha }}
|
|
body: |
|
|
Automated build of PNGTuber Plus
|
|
|
|
## Recent Updates by Litruv
|
|
- **StreamDeck Integration**: Add buttons to enable the streamdeck plugin that was built in
|
|
- **Rotation Wobble**: New sprite rotation effects with frequency and amplitude controls
|
|
- **Enhanced Modifier Keys**: Support for complex key combinations (Ctrl+Shift+Alt+Cmd)
|
|
- **Godot 4.4.1 Support**: Updated for latest Godot stable release
|
|
|
|
## Installation
|
|
1. Download PNGTuber-Plus.exe from the assets below
|
|
2. Run the executable - no installation required!
|
|
3. For StreamDeck integration, download the plugin from [here](https://github.com/BoyneGames/streamdeck-godot-plugin/releases/tag/1.0.0)
|
|
draft: false
|
|
prerelease: false
|
|
|
|
- name: Upload Windows Release Asset
|
|
uses: actions/upload-release-asset@v1
|
|
env:
|
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
with:
|
|
upload_url: ${{ steps.create_release.outputs.upload_url }}
|
|
asset_path: ./windows/PNGTuber-Plus.exe
|
|
asset_name: PNGTuber-Plus.exe
|
|
asset_content_type: application/octet-stream
|