-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added github action to create and publish nuget package
- Loading branch information
Showing
3 changed files
with
57 additions
and
5 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
name: Build and publish NuGet | ||
|
||
on: | ||
push: | ||
branches: [ master ] | ||
pull_request: | ||
branches: [ master ] | ||
|
||
jobs: | ||
publish: | ||
name: build, pack & publish | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Publish NuGet | ||
id: publishNuGet | ||
uses: brandedoutcast/publish-nuget@v2.5.5 | ||
with: | ||
# Filepath of the project to be packaged, relative to root of repository | ||
PROJECT_FILE_PATH: src/SpatialFocus.EntityFrameworkCore.Extensions/SpatialFocus.EntityFrameworkCore.Extensions.csproj | ||
# NuGet package id, used for version detection & defaults to project name | ||
PACKAGE_NAME: SpatialFocus.EntityFrameworkCore.Extensions | ||
# API key to authenticate with NuGet server | ||
NUGET_KEY: ${{secrets.NUGET_API_KEY}} | ||
# Flag to toggle pushing symbols along with nuget package to the server, disabled by default | ||
INCLUDE_SYMBOLS: true | ||
- name: Persist NuGet artifact | ||
uses: actions/upload-artifact@v1 | ||
if: ${{steps.publishNuGet.outputs.PACKAGE_NAME != ''}} | ||
with: | ||
name: ${{steps.publishNuGet.outputs.PACKAGE_NAME}} | ||
path: ${{steps.publishNuGet.outputs.PACKAGE_PATH}} | ||
- name: Persist SNuGet artifact | ||
uses: actions/upload-artifact@v1 | ||
if: ${{steps.publishNuGet.outputs.SYMBOLS_PACKAGE_NAME != ''}} | ||
with: | ||
name: ${{steps.publishNuGet.outputs.SYMBOLS_PACKAGE_NAME}} | ||
path: ${{steps.publishNuGet.outputs.SYMBOLS_PACKAGE_PATH}} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -136,6 +136,7 @@ publish/ | |
*.azurePubxml | ||
|
||
# NuGet Packages Directory | ||
.nuget/ | ||
packages/ | ||
*.nuget.targets | ||
*.lock.json | ||
|
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