1
+ name : Publish to NuGet
2
+ on :
3
+ push :
4
+ branches :
5
+ - master # Default release branch
6
+ jobs :
7
+ publish :
8
+ name : build, pack & publish
9
+ runs-on : ubuntu-latest
10
+ steps :
11
+ - uses : actions/checkout@v2
12
+
13
+ # Publish
14
+ - name : publish on version change
15
+ id : publish_nuget
16
+ uses : rohith/publish-nuget@v2
17
+ with :
18
+ # Filepath of the project to be packaged, relative to root of repository
19
+ PROJECT_FILE_PATH : src/Extensions.Configuration.Object/Extensions.Configuration.Object.csproj
20
+
21
+ # NuGet package id, used for version detection & defaults to project name
22
+ PACKAGE_NAME : Extensions.Configuration.Object
23
+
24
+ # Filepath with version info, relative to root of repository & defaults to PROJECT_FILE_PATH
25
+ # VERSION_FILE_PATH: Directory.Build.props
26
+
27
+ # Regex pattern to extract version info in a capturing group
28
+ VERSION_REGEX : ^\s*<Version>(.*)<\/Version>\s*$
29
+
30
+ # Useful with external providers like Nerdbank.GitVersioning, ignores VERSION_FILE_PATH & VERSION_REGEX
31
+ # VERSION_STATIC: 1.0.0
32
+
33
+ # Flag to toggle git tagging, enabled by default
34
+ # TAG_COMMIT: true
35
+
36
+ # Format of the git tag, [*] gets replaced with actual version
37
+ # TAG_FORMAT: v*
38
+
39
+ # API key to authenticate with NuGet server
40
+ NUGET_KEY : ${{secrets.NUGET_API_KEY}}
41
+
42
+ # NuGet server uri hosting the packages, defaults to https://api.nuget.org
43
+ NUGET_SOURCE : https://api.nuget.org
44
+
45
+ # Flag to toggle pushing symbols along with nuget package to the server, disabled by default
46
+ # INCLUDE_SYMBOLS: false
47
+
0 commit comments