Skip to content

Commit

Permalink
chore(CI): add pull request workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
DevilPepper committed Feb 1, 2021
1 parent 320ced3 commit 0c3e6f1
Showing 1 changed file with 47 additions and 0 deletions.
47 changes: 47 additions & 0 deletions .github/workflows/pull-request.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
name: Item Tracker CI

on:
pull_request:
branches: [ master ]

env:
Project_Name: MHWItemBoxTracker
configuration: Debug

defaults:
run:
shell: bash

build:
runs-on: windows-latest

steps:
- name: Checkout
uses: actions/checkout@v2

- name: Install .NET Core
uses: actions/setup-dotnet@v1
with:
dotnet-version: 5.0.x

- name: Setup MSBuild.exe
uses: microsoft/setup-msbuild@v1.0.2

# Restore the application to populate the obj folder with RuntimeIdentifiers
- name: Restore the applications
env:
NUGET_USERNAME: ${{ github.repository_owner }}
NUGET_PASSWORD: ${{ secrets.GITHUB_TOKEN }}
shell: pwsh
run: |
cp .github/NuGet.Config .
msbuild -m /t:Restore
- name: Execute unit tests
run: dotnet test

# if I had tests, I probably wouldn't need to build...
- name: Build the apps
shell: pwsh
run: |
msbuild -m /p:"Configuration=$env:configuration,AssemblyVersionNumber=0.0.0.0"

0 comments on commit 0c3e6f1

Please sign in to comment.