actions-marketplace-validations/Publish NuGet 2
Build, pack & publish nuget packages on project version change. Works with GPR. Forked from brandedoutcast/publish-nuget
View on GitHubTrust Signals
- Scorecard Score
- not yet scored
- Maintenance Recency
- Stale
- License
- None
- Runtime
- Deprecated runtime
Inputs
| name | description | required | default |
|---|---|---|---|
| PROJECT_FILE_PATH | Filepath of the project to be packaged, relative to root of repository | yes | — |
| PACKAGE_NAME | NuGet package id, used for version detection & defaults to project name | no | — |
| VERSION_FILE_PATH | Filepath with version info, relative to root of repository & defaults to PROJECT_FILE_PATH | no | — |
| VERSION_REGEX | Regex pattern to extract version info in a capturing group | no | ^\s*<Version>(.*)<\/Version>\s*$ |
| VERSION_STATIC | Useful with external providers like Nerdbank.GitVersioning, ignores VERSION_FILE_PATH & VERSION_REGEX | no | — |
| TAG_COMMIT | Flag to toggle git tagging, enabled by default | no | true |
| TAG_FORMAT | Format of the git tag, [*] gets replaced with actual version | no | v* |
| GITHUB_USER | Required for packages pushed to Github Package Registry. User allowed to push to repository, defaults to GITHUB_ACTOR (user that triggered the action) | no | — |
| NUGET_KEY | API key to authenticate with NuGet server, or a token, issued for GITHUB_USER if you use GPR | no | — |
| NUGET_SOURCE | NuGet server uri hosting the packages, defaults to https://api.nuget.org | no | https://api.nuget.org |
| INCLUDE_SYMBOLS | Flag to toggle pushing symbols along with nuget package to the server, disabled by default | no | false |
| THOW_ERROR_IF_VERSION_EXISTS | Flag to throw an error when trying to publish an existing version of a package | no | false |
| PACK_NO_BUILD | Adds the `--no-build` option to the `dotnet pack` command. Enabled by default. | no | true |
Outputs
| name | description |
|---|---|
| VERSION | Version of the associated git tag |
| PACKAGE_NAME | Name of the NuGet package generated |
| PACKAGE_PATH | Path to the generated NuGet package |
| SYMBOLS_PACKAGE_NAME | Name of the symbols package generated |
| SYMBOLS_PACKAGE_PATH | Path to the generated symbols package |