-
Notifications
You must be signed in to change notification settings - Fork 18
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
db26dac
commit ebe8dcb
Showing
1 changed file
with
47 additions
and
5 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,28 @@ | ||
name: Windows Build | ||
|
||
on: [workflow_dispatch, pull_request, push] | ||
on: | ||
workflow_dispatch: | ||
pull_request: | ||
push: | ||
branches: | ||
- 'master' | ||
- '1.0' | ||
- '1.1' | ||
jobs: | ||
job: | ||
BuildProject: | ||
name: ${{ matrix.os }}-${{ matrix.buildtype }} | ||
runs-on: ${{ matrix.os }} | ||
permissions: | ||
packages: write | ||
contents: write | ||
strategy: | ||
matrix: | ||
os: [windows-2022] | ||
buildtype: [windows-release, windows-release-asan, windows-debug] | ||
include: | ||
- os: windows-2022 | ||
triplet: x64-windows | ||
packages: > | ||
sccache | ||
outputs: | ||
upload_url: ${{ steps.upload_artifact.outputs.upload_url }} | ||
|
||
steps: | ||
- name: Checkout repository | ||
|
@@ -49,8 +58,41 @@ jobs: | |
run: | | ||
cd D:\a\BlackTek-Server\BlackTek-Server | ||
msbuild Black-Tek-Server.sln /p:Configuration=Release | ||
cmd /c copy Black-Tek-Server.exe BlackTek-Server-Release.exe | ||
- name: Compile Debug | ||
run: | | ||
cd D:\a\BlackTek-Server\BlackTek-Server | ||
msbuild Black-Tek-Server.sln /p:Configuration=Debug | ||
cmd copy Black-Tek-Server.exe BlackTek-Server-Debug.exe | ||
del Black-Tek-Server.exe | ||
cd D:\a\BlackTek-Server | ||
- name: Cleanup Vcpkg_installed | ||
uses: JesseTG/[email protected] | ||
with: | ||
path: D:/a/BlackTek-Server/BlackTek-Server/vcpkg_installed | ||
|
||
- name: Cleanup Intermediaries | ||
uses: JesseTG/[email protected] | ||
with: | ||
path: D:/a/BlackTek-Server/BlackTek-Server/build | ||
|
||
- name: Prepare Compressed Assets | ||
run: | | ||
7z a BlackTek-Server.zip D:/a/BlackTek-Server/BlackTek-Server/ | ||
- name: Upload Assets for Edge Build | ||
if: github.event_name == 'push' && !startsWith(github.ref, 'refs/tags/') || (github.event_name == 'pull_request' && github.event.pull_request.merged == true) | ||
uses: softprops/action-gh-release@v2 | ||
env: | ||
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
with: | ||
prerelease: true | ||
tag_name: Windows-Edge-Build-${{ github.sha }} | ||
name: BlackTek-Server-WindowsEdgeBuild-${{ github.sha }} | ||
body: | | ||
Windows Edge build from commit ${{ github.sha }} | ||
Commit message: ${{ github.event.head_commit.message }} | ||
Build date: ${{ github.event.head_commit.timestamp }} | ||
files: BlackTek-Server.zip |