Skip to content

ci: initial CI & CD #12

ci: initial CI & CD

ci: initial CI & CD #12

Workflow file for this run

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/Herve-M/lslib/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 build BG3ModManager.sln -c Publish --no-restore --nologo --self-contained false
- name: Pack
run: |
python BuildRelease.py
- 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