Skip to content

Merge pull request #25 from LtiLibrary/dependabot/nuget/src/LtiAdvant… #1

Merge pull request #25 from LtiLibrary/dependabot/nuget/src/LtiAdvant…

Merge pull request #25 from LtiLibrary/dependabot/nuget/src/LtiAdvant… #1

Workflow file for this run

name: .NET Core
on: [push, pull_request]
jobs:
ci:
runs-on: windows-latest
steps:
- uses: actions/checkout@v2
- name: Fetch tags
run: |
git fetch origin +refs/tags/*:refs/tags/*
git fetch --prune --unshallow
- name: Build Reason
run: "echo ref: ${{github.ref}} event: ${{github.event_name}}"
- name: Setup .NET Core 2.1
uses: actions/setup-dotnet@v1
with:
dotnet-version: 2.1.811
- name: Setup .NET Core
uses: actions/setup-dotnet@v1
with:
dotnet-version: 3.1.403
source-url: https://nuget.pkg.github.com/LtiLibrary/index.json
env:
NUGET_AUTH_TOKEN: ${{secrets.GITHUB_TOKEN}}
- name: Build
run: dotnet build --configuration Release
- name: Test
run: dotnet test --configuration Release --results-directory artifacts --no-build
- name: debug
run: |
pwd
ls
ls src
- name: Package
if: github.event_name != 'pull_request'
run: dotnet pack --configuration Release --no-build
- name: Publish nuget
if: github.event_name != 'pull_request'
run: dotnet nuget push src/*/bin/Release/*.nupkg --skip-duplicate
- name: Publish Release Packages
if: startsWith(github.ref, 'refs/tags/v')
run: dotnet nuget push src/*/bin/Release/*.nupkg --source https://api.nuget.org/v3/index.json --api-key ${{ secrets.NUGET_TOKEN }}
- name: Upload Artifacts
uses: actions/[email protected]
with:
name: artifacts
path: artifacts