Merge remote-tracking branch 'upstream/v2.1' into v2.1 #77
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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 |