get ansi formatted content when implemented #28
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: Build | |
on: | |
# Trigger the workflow on pushes to only the 'main' branch (this avoids duplicate checks being run e.g., for dependabot pull requests) | |
push: | |
branches: [ main ] | |
# Trigger the workflow on any pull request | |
pull_request: | |
jobs: | |
build-thunderstore: | |
name: Build Thunderstore Package | |
runs-on: ubuntu-latest | |
steps: | |
- name: Fetch Sources | |
uses: actions/checkout@v4 | |
with: | |
ref: ${{ github.event.release.tag_name }} | |
fetch-depth: 0 | |
filter: tree:0 | |
submodules: recursive | |
- name: Setup .NET environment | |
uses: actions/setup-dotnet@v4 | |
with: | |
dotnet-version: "8.0.100" | |
- name: Restore project | |
run: | | |
dotnet restore | |
dotnet tool restore | |
- name: Build and pack solution | |
run: | | |
dotnet build -c Release | |
- name: Upload Thunderstore artifact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: thunderstore-build | |
path: | | |
./*/bin/Release/*/dist/*.zip | |
./*/assets/thunderstore.toml.user | |
build-platform-binaries: | |
name: Build ${{ matrix.pack-type }} platform binary for ${{ matrix.target }} | |
runs-on: ${{ matrix.os }} | |
strategy: | |
fail-fast: false | |
matrix: | |
kind: [ 'linux', 'windows', 'macOS' ] | |
pack-type: [ 'zip', 'tarball', 'deb' ] | |
include: | |
- kind: 'linux' | |
target: 'linux-x64' | |
os: 'ubuntu-latest' | |
- kind: 'windows' | |
target: 'win-x64' | |
os: 'windows-latest' | |
- kind: 'macOS' | |
target: 'osx-x64' | |
os: 'macos-latest' | |
- pack-type: 'zip' | |
msbuild-target: 'CreateZip' | |
artifact-extension: '.zip' | |
- pack-type: 'deb' | |
msbuild-target: 'CreateDeb' | |
artifact-extension: '.deb' | |
- pack-type: 'tarball' | |
msbuild-target: 'CreateTarball' | |
artifact-extension: '.tar.gz' | |
exclude: | |
- kind: 'windows' | |
pack-type: 'tarball' | |
- kind: 'windows' | |
pack-type: 'deb' | |
- kind: 'macOS' | |
pack-type: 'deb' | |
steps: | |
- name: Fetch Sources | |
uses: actions/checkout@v4 | |
with: | |
ref: ${{ github.event.release.tag_name }} | |
fetch-depth: 0 | |
filter: tree:0 | |
submodules: recursive | |
- name: Setup .NET environment | |
uses: actions/setup-dotnet@v4 | |
with: | |
dotnet-version: "8.0.100" | |
- name: Restore project | |
run: | | |
dotnet restore | |
dotnet tool restore | |
- name: Build app project | |
run: | | |
dotnet build AvaloniaBepInExConsole.App/AvaloniaBepInExConsole.App.csproj -c ReleaseApp -t:${{ matrix.msbuild-target }} -r "${{ matrix.target }}" --self-contained true -f net8.0 | |
- name: Upload binary artifact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: ${{ matrix.target }}-binary-${{ matrix.pack-type }} | |
path: ./AvaloniaBepInExConsole.App/bin/ReleaseApp/net8.0/${{ matrix.target }}/*${{ matrix.artifact-extension }} |