Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
57 changes: 57 additions & 0 deletions .github/workflows/main.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
name: main

on:
push:
branches:
- master
tags:
- '*'
pull_request:
branches:
- master

jobs:
build:
runs-on: windows-latest
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Get LSLib
shell: pwsh
run: |
Invoke-WebRequest -Uri https://github.com/${{ vars.LSLIB_GITHUB }}/releases/download/${{ vars.LSLIB_VERSION }}/lslib-release.zip -OutFile lslib.zip
Expand-Archive -Path lslib.zip -DestinationPath external/lslib

- uses: actions/setup-dotnet@v3
with:
dotnet-version: '7.x'

- name: Restore
run: dotnet restore BG3ModManager.sln

- name: Build
run: dotnet msbuild BG3ModManager.sln -p:Configuration=Publish

- name: Uploading artifact
uses: actions/upload-artifact@v4
with:
name: BUILD
path: ./BG3ModManager_Latest.zip

release:
runs-on: ubuntu-latest
needs: build
if: ${{ startsWith(github.ref, 'refs/tags/') }}
steps:
- uses: actions/download-artifact@v4
id: download
with:
name: BUILD

- name: Release
uses: softprops/action-gh-release@v1
if: startsWith(github.ref, 'refs/tags/')
with:
files: |
${{steps.download.outputs.download-path}}/BG3ModManager_Latest.zip