Skip to content

Remote Ping changes #250

Remote Ping changes

Remote Ping changes #250

name: Build and test
on:
push:
pull_request:
workflow_dispatch:
jobs:
build:
runs-on: windows-latest
# Do not run duplicate actions on pull_request.
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name
steps:
- uses: actions/checkout@v3
with:
submodules: true
- name: Setup .NET 8
uses: actions/setup-dotnet@v3
with:
dotnet-version: 8.0.x
# This is a workaround for issue https://github.com/actions/virtual-environments/issues/1090,
# which causes to nuget restores to fail
- name: Clean NuGet cache
run: dotnet nuget locals all --clear
- name: Build
run: dotnet build PlenBotLogUploader.csproj -c Release
- name: Test
run: dotnet test PlenBotLogUploader.csproj --no-restore --verbosity normal
- name: Package PlenBotLogUploader (Windows)
run: dotnet publish PlenBotLogUploader.csproj -c Release -r win-x64 --self-contained=false -p:PublishSingleFile=true -p:IncludeNativeLibrariesForSelfExtract=true -p:IncludeAllContentForSelfExtract=true -o artifacts/uploader/win64/
- name: Package PlenBotLogUploader (Windows, self-contained)
run: dotnet publish PlenBotLogUploader.csproj -c Release -r win-x64 --self-contained=true -p:PublishSingleFile=true -p:IncludeNativeLibrariesForSelfExtract=true -p:IncludeAllContentForSelfExtract=true -o artifacts/uploader/win64-sc/
- name: Bundle PDBs
run: |
mkdir -p artifacts/pdb/uploader/win64/
mv artifacts/uploader/win64/*.pdb artifacts/pdb/uploader/win64/
- name: Upload PlenBotLogUploader (Windows)
uses: actions/[email protected]
with:
name: PlenBotLogUploader (Windows, netv8)
path: artifacts/uploader/win64/PlenBotLogUploader.exe
- name: Upload PlenBotLogUploader (Windows, self-contained)
uses: actions/[email protected]
with:
name: PlenBotLogUploader (Windows, self-contained)
path: artifacts/uploader/win64-sc/PlenBotLogUploader.exe
- name: Upload PDB files
uses: actions/[email protected]
with:
name: PDB files
path: artifacts/pdb/