API Reference
Cmdlet
Invoke-DotNetRepositoryRelease
Repository-wide .NET package release workflow (discover, version, pack, publish).
Remarks
Discovers packable projects, resolves a repository-wide version (supports X-pattern), updates csproj versions, packs, and optionally publishes packages.
Examples
Release packages using X-pattern versioning
Invoke-DotNetRepositoryRelease -Path . -ExpectedVersion '1.2.X' -Publish -PublishApiKey $env:NUGET_API_KEY
Release packages with exclusions and custom sources
Invoke-DotNetRepositoryRelease -Path . -ExpectedVersion '2.0.X' -ExcludeProject 'OfficeIMO.Visio' -NugetSource 'C:\Packages' -Publish -PublishApiKey $env:NUGET_API_KEY
Common Parameters
This command supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable.
For more information, see about_CommonParameters.
Syntax
Invoke-DotNetRepositoryRelease [-CertificateStore <CurrentUser|LocalMachine>] [-CertificateThumbprint <String>] [-Configuration <Release|Debug>] [-ExcludeDirectories <String[]>] [-ExcludeProject <String[]>] [-ExpectedVersion <String>] [-ExpectedVersionMap <IDictionary>] [-ExpectedVersionMapAsInclude] [-ExpectedVersionMapUseWildcards] [-IncludePrerelease] [-IncludeProject <String[]>] [-NugetCredentialSecret <String>] [-NugetCredentialSecretEnvName <String>] [-NugetCredentialSecretFilePath <String>] [-NugetCredentialUserName <String>] [-NugetSource <String[]>] [-OutputPath <String>] [-Path <String>] [-Publish] [-PublishApiKey <String>] [-PublishApiKeyEnvName <String>] [-PublishApiKeyFilePath <String>] [-PublishFailFast] [-PublishSource <String>] [-SkipDuplicate] [-SkipPack] [-TimeStampServer <String>] [<CommonParameters>]
#
Parameter set:
All Parameter SetsParameters
- CertificateStore CertificateStoreLocation
- Certificate store location used when searching for the signing certificate.
- Possible values:
CurrentUser,LocalMachine - CertificateThumbprint String
- Certificate thumbprint used for signing packages.
- Configuration String
- Build configuration (Release/Debug).
- Possible values:
Release,Debug - ExcludeDirectories String[]
- Directory names to exclude from discovery.
- ExcludeProject String[]
- Project names to exclude (csproj file name without extension).
- ExpectedVersion String
- Expected version (exact or X-pattern, e.g. 1.2.X).
- ExpectedVersionMap IDictionary
- Per-project expected versions (hashtable: ProjectName = Version).
- ExpectedVersionMapAsInclude SwitchParameter
- When set, only projects listed in ExpectedVersionMap are processed.
- ExpectedVersionMapUseWildcards SwitchParameter
- Allow wildcards (*, ?) in ExpectedVersionMap keys.
- IncludePrerelease SwitchParameter
- Include prerelease versions when resolving versions.
- IncludeProject String[]
- Project names to include (csproj file name without extension).
- NugetCredentialSecret String
- Credential secret/token for private NuGet sources.
- NugetCredentialSecretEnvName String
- Name of environment variable containing the credential secret/token.
- NugetCredentialSecretFilePath String
- Path to a file containing the credential secret/token.
- NugetCredentialUserName String
- Credential username for private NuGet sources.
- NugetSource String[]
- NuGet sources (v3 index or local path) used for version resolution.
- OutputPath String
- Optional output path for packages.
- Path String
- Root repository path.
- Publish SwitchParameter
- Publish packages to the feed.
- PublishApiKey String
- API key used for publishing packages.
- PublishApiKeyEnvName String
- Name of environment variable containing the publish API key.
- PublishApiKeyFilePath String
- Path to a file containing the publish API key.
- PublishFailFast SwitchParameter
- Stop on the first publish/signing failure.
- PublishSource String
- NuGet feed source for publishing.
- SkipDuplicate SwitchParameter
- Skip duplicates when pushing packages.
- SkipPack SwitchParameter
- Skip dotnet pack step.
- TimeStampServer String
- Timestamp server URL used while signing packages.
Outputs
PowerForge.DotNetRepositoryReleaseResult