Build artifact. #37
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 artifact. | |
on: | |
push: | |
branches: '*' | |
pull_request: | |
branches: '*' | |
workflow_dispatch: | |
schedule: | |
- cron: '0 0 1 * *' | |
jobs: | |
build: | |
runs-on: windows-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
with: | |
submodules: recursive | |
# Install the .NET Core workload | |
- name: Install .NET | |
uses: actions/setup-dotnet@v2 | |
with: | |
dotnet-version: 6.0.x | |
# Create the app package by building and packaging the Windows Application Packaging project | |
- name: Build the app | |
run: | | |
cd AmpHelper.CLI | |
dotnet publish -c Release -o ../publish/AmpHelper.CLI -r win-x64 -p:PublishSingleFile=true --self-contained=false | |
dotnet publish -c Release -o ../publish/AmpHelper.CLI.Self-Contained -r win-x64 -p:PublishSingleFile=true -p:PublishTrimmed=true --self-contained=true | |
- name: Upload framework dependent build | |
uses: actions/[email protected] | |
with: | |
name: "AmpHelper" | |
path: publish/AmpHelper.CLI/AmpHelper.exe | |
retention-days: 90 | |
- name: Upload self-contained build | |
uses: actions/[email protected] | |
with: | |
name: "AmpHelper" | |
path: publish/AmpHelper.CLI.Self-Contained/AmpHelper.exe | |
retention-days: 90 |