LANCommander/.github/workflows/LANCommander.yml

50 lines
1.4 KiB
YAML
Raw Permalink Normal View History

2023-04-03 22:24:47 +00:00
# This workflow will build a .NET project
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-net
2023-04-03 22:34:11 +00:00
name: LANCommander
2023-04-03 22:24:47 +00:00
on:
push:
2023-04-05 22:30:32 +00:00
paths:
- 'LANCommander/**'
- 'LANCommander.PCGamingWiki/**'
- 'LANCommander.SDK/**'
2023-04-03 22:24:47 +00:00
pull_request:
2023-04-05 22:30:32 +00:00
paths:
- 'LANCommander/**'
- 'LANCommander.PCGamingWiki/**'
- 'LANCommander.SDK/**'
workflow_dispatch:
2023-04-03 22:24:47 +00:00
jobs:
build:
2023-08-29 01:33:02 +00:00
runs-on: windows-latest
2023-04-03 22:24:47 +00:00
steps:
- uses: actions/checkout@v3
- name: Setup .NET
uses: actions/setup-dotnet@v3
with:
dotnet-version: 6.0.x
- name: Restore dependencies
run: dotnet restore
2023-08-28 06:31:29 +00:00
- name: Setup Node.js environment
uses: actions/setup-node@v3.8.1
2023-08-28 06:36:56 +00:00
- run: cd LANCommander/wwwroot/scripts; npm install
2023-04-03 22:24:47 +00:00
- name: Build
run: dotnet build "./LANCommander/LANCommander.csproj" --no-restore
- name: Publish
2023-04-05 00:46:06 +00:00
run: dotnet publish "./LANCommander/LANCommander.csproj" -c Release -o _Build --self-contained --os win -p:PublishSingleFile=true
2023-09-03 19:16:32 +00:00
- name: Sign Windows Binary
2023-09-03 20:06:52 +00:00
uses: nadeemjazmawe/Sign-action-signtool.exe@v0.1
2023-09-03 19:43:32 +00:00
with:
certificate: "${{ secrets.CERTIFICATE }}"
2023-09-03 20:06:52 +00:00
cert-password: "${{ secrets.CERTIFICATE_PASSWORD }}"
filepath: "./_Build/LANCommander.exe"
- name: Upload Artifacts
uses: actions/upload-artifact@v2
with:
name: LANCommander
2023-04-05 00:24:33 +00:00
path: "./_Build"