mirror of
https://github.com/yquake2/ctf.git
synced 2024-11-14 00:11:18 +00:00
b8a45290a2
This is equivalent to the CI workflows added to the yquake2 main repository. The workflows are triggered on commit, for new pull requests and when the pull request branch is updated. The CI is mostly for providing users with up to date test builds.
56 lines
1.6 KiB
YAML
56 lines
1.6 KiB
YAML
name: Testbuild for Win32
|
|
run-name: testbuild_win32
|
|
on:
|
|
push:
|
|
branches:
|
|
- 'master'
|
|
pull_request:
|
|
types:
|
|
- edited
|
|
- opened
|
|
- synchronize
|
|
concurrency:
|
|
# Cancel concurrent workflows for the same PR or commit hash.
|
|
group: ${{github.workflow}}-${{github.event_name == 'pull_request' && github.head_ref || github.sha}}
|
|
cancel-in-progress: true
|
|
jobs:
|
|
build_mingw_x86_32:
|
|
runs-on: windows-latest
|
|
strategy:
|
|
fail-fast: false
|
|
matrix:
|
|
include:
|
|
- { sys: mingw32, env: i686 }
|
|
steps:
|
|
- uses: msys2/setup-msys2@v2
|
|
with:
|
|
msystem: ${{matrix.sys}}
|
|
update: true
|
|
install: >-
|
|
git
|
|
make
|
|
mingw-w64-${{matrix.env}}-gcc
|
|
mingw-w64-${{matrix.env}}-make
|
|
- name: Check out repository code
|
|
uses: actions/checkout@v4
|
|
- name: Build
|
|
shell: msys2 {0}
|
|
run: |
|
|
# Public runners come with 2 CPUs.
|
|
make -j2
|
|
- name: Create testbuild package
|
|
shell: msys2 {0}
|
|
run: |
|
|
# Create release directory tree
|
|
mkdir -p publish/quake2-ctf-win32-${{github.sha}}/misc/docs
|
|
# Copy release assets
|
|
cp -r release/* publish/quake2-ctf-win32-${{github.sha}}/
|
|
# Copy misc assets
|
|
cp LICENSE publish/quake2-ctf-win32-${{github.sha}}/misc/docs/LICENSE.txt
|
|
cp README.md publish/quake2-ctf-win32-${{github.sha}}/misc/docs/README.txt
|
|
- name: Upload testbuild package
|
|
uses: actions/upload-artifact@v4
|
|
with:
|
|
name: quake2-ctf-win32-${{github.sha}}
|
|
path: publish/
|
|
if-no-files-found: error
|