You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
88 lines
2.4 KiB
88 lines
2.4 KiB
name: Xbox One / Series |
|
|
|
on: |
|
push: |
|
branches: |
|
- master |
|
paths-ignore: |
|
- '*.md' |
|
- 'docs/**' |
|
pull_request: |
|
types: [opened, synchronize] |
|
paths-ignore: |
|
- '*.md' |
|
- 'docs/**' |
|
release: |
|
types: [published] |
|
paths-ignore: |
|
- '*.md' |
|
- 'docs/**' |
|
|
|
concurrency: |
|
group: ${{ github.workflow }}-${{ github.ref }} |
|
cancel-in-progress: true |
|
|
|
jobs: |
|
build: |
|
runs-on: windows-latest |
|
steps: |
|
- name: Checkout |
|
uses: actions/checkout@v6 |
|
with: |
|
fetch-depth: 0 |
|
|
|
- name: ccache |
|
uses: hendrikmuhs/ccache-action@v1.2 |
|
|
|
- name: Add msbuild to PATH |
|
uses: microsoft/setup-msbuild@v2 |
|
with: |
|
msbuild-architecture: x64 |
|
|
|
- name: Configure git |
|
shell: cmd |
|
run: | |
|
git config --global core.filemode false |
|
git config --global core.autocrlf false |
|
|
|
- name: Install gettext |
|
run: > |
|
New-Item -Path . -Name tools-gettext -ItemType Directory -Force && |
|
Invoke-WebRequest -Uri "https://github.com/vslavik/gettext-tools-windows/releases/download/v0.22.5/gettext-tools-windows-0.22.5.zip" -OutFile tools-gettext.zip -Resume && |
|
Expand-Archive tools-gettext.zip && |
|
Remove-Item tools-gettext.zip && |
|
Add-Content $env:GITHUB_PATH "$((Get-Item tools-gettext).FullName)\bin" |
|
|
|
- name: Build |
|
shell: cmd |
|
run: | |
|
cd ${{ github.workspace }}\Packaging\xbox-one |
|
build.bat |
|
|
|
- name: Copy artifacts to package directory |
|
run: > |
|
New-Item -Path build\uwp-project -Name pkg -ItemType Directory -Force && |
|
Get-Childitem -Path build\uwp-project\AppxPackages, build\uwp-project\Release |
|
-Include Microsoft.VCLibs.x64.*.appx, devilutionX_*_x64.appx -File -Recurse | |
|
Copy-Item -Destination build\uwp-project\pkg\ |
|
|
|
- name: Upload-Package |
|
if: ${{ !env.ACT }} |
|
uses: actions/upload-artifact@v7 |
|
with: |
|
name: devilutionx-xbox-one-series |
|
if-no-files-found: error |
|
path: | |
|
build/uwp-project/pkg/ |
|
|
|
- name: Package Release |
|
if: ${{ github.event_name == 'release' && !env.ACT }} |
|
working-directory: ${{github.workspace}}/build/uwp-project/pkg/ |
|
run: 7z a -r ../../../devilutionx-xbox-one-series.zip . |
|
|
|
- name: Update Release |
|
if: ${{ github.event_name == 'release' && !env.ACT }} |
|
uses: svenstaro/upload-release-action@v2 |
|
with: |
|
file: devilutionx-xbox-one-series.zip |
|
overwrite: true
|
|
|