forked from allegory-software/allegory-sdk-luajit
-
Notifications
You must be signed in to change notification settings - Fork 0
57 lines (51 loc) · 1.95 KB
/
push.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
name: Main Workflow
on:
push:
pull_request:
release:
types:
- created
jobs:
build:
if: "!contains(github.event.head_commit.message, '[skip ci]') || github.event_name == 'release'"
runs-on: windows-latest
strategy:
fail-fast: false
matrix:
Configuration: [Release]
Platform: [x86, x64]
steps:
- uses: actions/[email protected]
with:
fetch-depth: 0
- name: Setup MSBuild
uses: microsoft/[email protected]
- name: MSBuild
shell: cmd
run: |
set APPVEYOR_BUILD_VERSION=2.1.${{ github.run_number }}
msbuild LuaJIT.sln /t:Rebuild /p:Configuration=${{ matrix.Configuration }} /p:Platform=${{ matrix.Platform }}
- name: Prepare artifacts
shell: cmd
run: |
set APPVEYOR_BUILD_VERSION=2.1.${{ github.run_number }}
set CONFIGURATION=${{ matrix.Configuration }}
set PLATFORM=${{ matrix.Platform }}
set ARTIFACT_NAME=LuaJIT_%PLATFORM%_%APPVEYOR_BUILD_VERSION%_%CONFIGURATION%.7z
cd bin\%PLATFORM%\
7z a -t7z -m0=LZMA2:d=96m:fb=273 -mx=9 -mmt=2 ..\..\%ARTIFACT_NAME% .\
- name: Upload OGSR artifact
uses: actions/[email protected]
with:
name: LuaJIT_${{ matrix.Platform }}_2.1.${{ github.run_number }}_${{ matrix.Configuration }}.7z
path: .\LuaJIT_${{ matrix.Platform }}_2.1.${{ github.run_number }}_${{ matrix.Configuration }}.7z
- name: Upload release asset
if: github.event_name == 'release'
uses: tanyagray/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: .\LuaJIT_${{ matrix.Platform }}_2.1.${{ github.run_number }}_${{ matrix.Configuration }}.7z
asset_name: LuaJIT_${{ matrix.Platform }}_2.1.${{ github.run_number }}_${{ matrix.Configuration }}.7z
asset_content_type: application/zip