API Reference
New-ConfigurationDelivery
Configures delivery metadata for bundling and installing internal docs/examples.
Remarks
Delivery configuration is used to bundle “internals” (docs, examples, tools, configuration files) into a module and optionally generate public helper commands (Install-<ModuleName> / Update-<ModuleName>) that can copy these files to a target folder. This is intended for “script packages” where the module contains additional artifacts that should be deployed alongside it. Generated install helpers default to merge behavior. Generated update helpers default to refresh behavior, which overwrites package files while keeping local files that are not part of the package. Use IncludePaths and ExcludePaths to scope which package files are managed, then use PreservePaths and OverwritePaths to fine-tune collision behavior for managed relative paths.
Examples
Bundle Internals and generate Install/Update commands
PS>
New-ConfigurationDelivery -Enable -InternalsPath 'Internals' -IncludeRootReadme -IncludeRootChangelog -GenerateInstallCommand -GenerateUpdateCommand -Sign
Generates public Install/Update helpers, bundles README/CHANGELOG into the module, and requests signing for bundled internals during build.
Configure repository-backed docs display
PS>
New-ConfigurationDelivery -Enable -RepositoryPaths 'docs' -RepositoryBranch 'main' -DocumentationOrder '01-Intro.md','02-HowTo.md'
Helps modules expose docs from a repository path in a consistent order.
Configure merge policies and custom helper names
PS>
New-ConfigurationDelivery -Enable -GenerateInstallCommand -GenerateUpdateCommand -InstallCommandName 'Install-ContosoToolkit' -UpdateCommandName 'Update-ContosoToolkit' -IncludePaths 'Config/**','Scripts/*.ps1' -ExcludePaths 'Config/local/**' -PreservePaths 'Config/config.json' -OverwritePaths 'Bin/**','Templates/**'
Generates custom delivery helpers, manages only selected package files, excludes local-only configuration paths, preserves the active configuration during refresh updates, and can refresh selected paths during merge installs.
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
New-ConfigurationDelivery [-ChangelogDestination <Internals|Root|Both>] [-DocumentationOrder <String[]>] [-Enable] [-ExcludePaths <String[]>] [-GenerateInstallCommand] [-GenerateUpdateCommand] [-ImportantLinks <DeliveryImportantLink[]>] [-IncludePaths <String[]>] [-IncludeRootChangelog] [-IncludeRootLicense] [-IncludeRootReadme] [-InstallCommandName <String>] [-InternalsPath <String>] [-IntroFile <String>] [-IntroText <String[]>] [-LicenseDestination <Internals|Root|Both>] [-OverwritePaths <String[]>] [-PreservePaths <String[]>] [-ReadmeDestination <Internals|Root|Both>] [-RepositoryBranch <String>] [-RepositoryPaths <String[]>] [-Sign] [-UpdateCommandName <String>] [-UpgradeFile <String>] [-UpgradeText <String[]>] [<CommonParameters>]#All Parameter SetsParameters
- ChangelogDestination DeliveryBundleDestination
- Where to bundle CHANGELOG.* within the built module.
- Possible values:
Internals,Root,Both - DocumentationOrder String[]
- Optional file-name order for Internals\\Docs when rendering documentation.
- Enable SwitchParameter
- Enables delivery metadata emission.
- ExcludePaths String[]
- Optional wildcard patterns (relative to InternalsPath) that generated Install-/Update- helpers should not copy, refresh, or consider package-owned. Exclusions win over IncludePaths. Use this for local-only or user-owned package-adjacent paths such as Config/local/** or Config/config.json.
- GenerateInstallCommand SwitchParameter
- When set, generates a public Install-<ModuleName> helper function during build that copies Internals to a destination folder.
- GenerateUpdateCommand SwitchParameter
- When set, generates a public Update-<ModuleName> helper function during build that delegates to the install command in refresh mode by default.
- ImportantLinks DeliveryImportantLink[]
- Important links (Title/Url). Accepts legacy hashtable array (@{ Title='..'; Url='..' }) or DeliveryImportantLink[].
- IncludePaths String[]
- Optional wildcard patterns (relative to InternalsPath) that define which package files generated Install-/Update- helpers manage. Use this when a module ships mixed content but only selected folders should be copied or refreshed, for example Config/*.sample.json and Scripts/*.ps1. When omitted, all files under InternalsPath are managed.
- IncludeRootChangelog SwitchParameter
- Include module root CHANGELOG.* during installation.
- IncludeRootLicense SwitchParameter
- Include module root LICENSE.* during installation.
- IncludeRootReadme SwitchParameter
- Include module root README.* during installation.
- InstallCommandName String
- Optional override name for the generated install command. When empty, defaults to Install-<ModuleName>.
- InternalsPath String
- Relative path inside the module that contains internal deliverables.
- IntroFile String
- Relative path (within the module root) to a Markdown/text file to use as Intro content.
- IntroText String[]
- Text lines shown to users after Install-ModuleDocumentation completes.
- LicenseDestination DeliveryBundleDestination
- Where to bundle LICENSE.* within the built module.
- Possible values:
Internals,Root,Both - OverwritePaths String[]
- Optional wildcard patterns (relative to Internals) that should be overwritten during merge installs by generated Install-/Update- helpers. Example: Artefacts/**.
- PreservePaths String[]
- Optional wildcard patterns (relative to Internals) that should be preserved during merge or refresh installs by generated Install-/Update- helpers. Example: Config/**.
- ReadmeDestination DeliveryBundleDestination
- Where to bundle README.* within the built module.
- Possible values:
Internals,Root,Both - RepositoryBranch String
- Optional branch name to use when fetching remote documentation.
- RepositoryPaths String[]
- One or more repository-relative paths from which to display remote documentation files.
- Sign SwitchParameter
- When set, requests signing for files under InternalsPath using the configured module signing settings/certificate.
- UpdateCommandName String
- Optional override name for the generated update command. When empty, defaults to Update-<ModuleName>.
- UpgradeFile String
- Relative path (within the module root) to a Markdown/text file to use for Upgrade instructions.
- UpgradeText String[]
- Text lines with upgrade instructions shown when requested.