Add dotnet run task #41
This file contains hidden or 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: | |
workflow_dispatch: | |
push: | |
branches: [ "master" ] | |
pull_request: | |
jobs: | |
build: | |
permissions: | |
contents: write | |
pull-requests: write | |
runs-on: windows-latest | |
env: | |
Solution_Path: Flow.Launcher.Plugin.ClipboardPlus.sln | |
Project_Path: build\Build.csproj | |
steps: | |
# Checkout codes | |
- name: Checkout | |
uses: actions/checkout@v4 | |
# Install the .NET Core workload | |
- name: Setup .NET | |
uses: actions/setup-dotnet@v4 | |
with: | |
dotnet-version: | | |
7.0.x | |
8.0.x | |
# Restore dependencies for entire solution | |
- name: Restore dependencies | |
run: dotnet restore ${{ env.Solution_Path }} | |
# Build the entire solution | |
- name: Build | |
run: dotnet build ${{ env.Solution_Path }} --configuration Release | |
# Execute all unit tests in the solution | |
- name: Execute unit tests | |
run: dotnet test ${{ env.Solution_Path }} --configuration Release --no-build | |
# Run the build task | |
- name: Build | |
run: dotnet run --project build/Build.csproj ${{ env.Project_Path }} | |
# Upload the Build package | |
- name: Upload Build package | |
uses: actions/upload-artifact@v4 | |
with: | |
name: Build Package | |
path: | | |
output/Clipboard+*.zip | |
compression-level: 0 |