2020-06-08 08:19:34 +00:00
|
|
|
name: CI
|
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches-ignore: [ gh-pages, master ]
|
|
|
|
paths-ignore:
|
|
|
|
- '.github/*'
|
|
|
|
- '.github/ISSUE_TEMPLATE/**'
|
|
|
|
- 'docs/**'
|
|
|
|
- '*.md'
|
|
|
|
- '*.yml'
|
|
|
|
- 'LICENSE'
|
|
|
|
pull_request:
|
|
|
|
branches-ignore: [ gh-pages, master ]
|
|
|
|
paths-ignore:
|
|
|
|
- '.github/*'
|
|
|
|
- '.github/ISSUE_TEMPLATE/**'
|
|
|
|
- 'docs/**'
|
|
|
|
- '*.md'
|
|
|
|
- '*.yml'
|
|
|
|
- 'LICENSE'
|
|
|
|
|
|
|
|
jobs:
|
2020-07-11 13:45:12 +00:00
|
|
|
build:
|
2020-06-08 08:19:34 +00:00
|
|
|
runs-on: windows-latest
|
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
matrix:
|
2020-07-11 13:45:12 +00:00
|
|
|
cpu_arch: [AVX, AVX2, AVX512]
|
2020-06-08 08:19:34 +00:00
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v2
|
|
|
|
with:
|
|
|
|
fetch-depth: 0
|
2020-07-11 13:45:12 +00:00
|
|
|
|
2020-06-08 08:19:34 +00:00
|
|
|
- name: Setup
|
|
|
|
run: .\xb setup
|
2020-07-11 13:45:12 +00:00
|
|
|
|
2020-06-08 08:19:34 +00:00
|
|
|
- name: Build
|
|
|
|
run: .\xb build --cpu_arch=${{ matrix.cpu_arch }} --config=Release --target=src\xenia-app --target=src\xenia-vfs-dump
|
2020-07-11 13:45:12 +00:00
|
|
|
|
2020-06-08 08:19:34 +00:00
|
|
|
- name: Prepare artifacts
|
|
|
|
run: |
|
2020-07-11 13:45:12 +00:00
|
|
|
robocopy build\bin\Windows\Release artifacts xenia*.exe
|
|
|
|
robocopy . artifacts LICENSE
|
|
|
|
$LastExitCode = 0
|
|
|
|
cd artifacts
|
|
|
|
7z a ..\xenia_canary.zip LICENSE xenia_canary.exe
|
|
|
|
- uses: actions/upload-artifact@master
|
2020-06-08 08:19:34 +00:00
|
|
|
with:
|
2020-07-11 13:45:12 +00:00
|
|
|
name: xenia-canary-${{matrix.cpu_arch}}
|
|
|
|
path: artifacts
|
|
|
|
|
|
|
|
- name: Create Release
|
|
|
|
if: github.event.action != 'pull_request' && matrix.cpu_arch == 'AVX'
|
2020-06-08 08:19:34 +00:00
|
|
|
id: create_release
|
2020-07-11 13:45:12 +00:00
|
|
|
uses: actions/create-release@v1
|
2020-06-08 08:19:34 +00:00
|
|
|
env:
|
2020-07-11 13:45:12 +00:00
|
|
|
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
|
2020-06-08 08:19:34 +00:00
|
|
|
with:
|
2020-07-11 13:45:12 +00:00
|
|
|
tag_name: tag-${{github.sha}}
|
|
|
|
release_name: xenia-canary-${{github.sha}}
|
|
|
|
body: |
|
|
|
|
Changes in this Release
|
|
|
|
- First Change
|
|
|
|
- Second Change
|
|
|
|
- name: Upload Release Asset
|
|
|
|
if: github.event.action != 'pull_request' && matrix.cpu_arch == 'AVX'
|
|
|
|
id: upload-release-asset
|
|
|
|
uses: actions/upload-release-asset@v1.0.1
|
2020-06-08 08:19:34 +00:00
|
|
|
env:
|
2020-07-11 13:45:12 +00:00
|
|
|
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
|
2020-06-08 08:19:34 +00:00
|
|
|
with:
|
2020-07-11 13:45:12 +00:00
|
|
|
upload_url: ${{steps.create_release.outputs.upload_url}}
|
|
|
|
asset_path: ./xenia_canary.zip
|
2020-06-08 08:19:34 +00:00
|
|
|
asset_name: xenia_canary.zip
|
2020-07-11 13:45:12 +00:00
|
|
|
asset_content_type: application/zip
|