API Reference
New-ConfigurationModuleBuildProfile
Emits a reusable module build profile for common PowerForge module builds.
Remarks
This cmdlet emits the same configuration segment types as the lower-level New-ConfigurationFormat, New-ConfigurationDocumentation, New-ConfigurationValidation, New-ConfigurationFileConsistency, New-ConfigurationCompatibility, New-ConfigurationImportModule, and New-ConfigurationBuild commands. Use it when a module wrapper should stay thin and only declare project-specific values.
Examples
Use standard script-module defaults
New-ConfigurationModuleBuildProfile
Use binary-module defaults with an owned .NET project
New-ConfigurationModuleBuildProfile -Profile Binary -NETProjectName MyModule -NETProjectPath Sources\MyModule
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-ConfigurationModuleBuildProfile [-AboutTopicsSourcePath <String[]>] [-CertificateThumbprint <String>] [-Compatibility <Boolean>] [-Documentation <Boolean>] [-DocumentationPath <String>] [-DocumentationReadmePath <String>] [-DoNotAttemptToFixRelativePaths] [-DotSourceClasses] [-DotSourceLibraries] [-EnableScriptAnalyzer <Boolean>] [-EncodingOverrides <Hashtable>] [-FileConsistency <Boolean>] [-FileConsistencyExcludeDirectories <String[]>] [-ImportRequiredModules <Boolean>] [-ImportSelf <Boolean>] [-InstallMissingModules <Boolean>] [-KillLockersBeforeInstall] [-KillLockersForce] [-MergeFunctionsFromApprovedModules <Boolean>] [-MergeModuleOnBuild <Boolean>] [-MinimumCompatibilityPercentage <Int32>] [-NETAssemblyLoadContext] [-NETAssemblyTypeAcceleratorAssemblies <String[]>] [-NETAssemblyTypeAcceleratorMode <AllowList|Assembly|Enums>] [-NETAssemblyTypeAccelerators <String[]>] [-NETConfiguration <Release|Debug>] [-NETFramework <String[]>] [-NETHandleAssemblyWithSameName] [-NETProjectName <String>] [-NETProjectPath <String>] [-Profile <Standard|Binary>] [-RequiredEncoding <ASCII>] [-RequiredLineEnding <CRLF|LF>] [-ResolveBinaryConflicts] [-ResolveBinaryConflictsName <String>] [-SignIncludeBinaries] [-SignIncludeExe] [-SignIncludeInternals] [-SignModule <Boolean>] [-SkipBuiltinReplacements] [-SyncExternalHelpToProjectRoot <Boolean>] [-Validation <Boolean>] [-VersionedInstallKeep <Int32>] [-VersionedInstallStrategy <Exact|AutoRevision>] [<CommonParameters>]#All Parameter SetsParameters
- AboutTopicsSourcePath String[]
- Source paths for about-topic files.
- CertificateThumbprint String
- Code-signing certificate thumbprint.
- Compatibility Boolean
- Enable cross-version PowerShell compatibility defaults.
- Documentation Boolean
- Enable documentation generation defaults.
- DocumentationPath String
- Generated documentation path.
- DocumentationReadmePath String
- Readme path used by generated documentation.
- DoNotAttemptToFixRelativePaths SwitchParameter
- Do not attempt to fix relative paths during merge.
- DotSourceClasses SwitchParameter
- Keep classes dot-sourced.
- DotSourceLibraries SwitchParameter
- Keep library-loading code dot-sourced.
- EnableScriptAnalyzer Boolean
- Enable PSScriptAnalyzer as part of validation.
- EncodingOverrides Hashtable
- Per-pattern encoding overrides for file consistency checks.
- FileConsistency Boolean
- Enable file consistency defaults.
- FileConsistencyExcludeDirectories String[]
- Directory names excluded from file consistency checks.
- ImportRequiredModules Boolean
- Import RequiredModules before validation/test steps that need them.
- ImportSelf Boolean
- Import the module under build before validation/test steps that need it.
- InstallMissingModules Boolean
- Install missing module dependencies on the build host.
- KillLockersBeforeInstall SwitchParameter
- Kill locking processes before install.
- KillLockersForce SwitchParameter
- Force killing locking processes before install.
- MergeFunctionsFromApprovedModules Boolean
- Merge referenced functions from approved modules.
- MergeModuleOnBuild Boolean
- Merge module source files during build.
- MinimumCompatibilityPercentage Int32
- Minimum percentage of cross-compatible files.
- NETAssemblyLoadContext SwitchParameter
- Load binary module dependencies through an AssemblyLoadContext on PowerShell Core.
- NETAssemblyTypeAcceleratorAssemblies String[]
- Assembly names whose public types may be exposed as PowerShell type accelerators.
- NETAssemblyTypeAcceleratorMode AssemblyTypeAcceleratorExportMode
- Controls type accelerator exposure for binary-module dependencies.
- Possible values:
AllowList,Assembly,Enums - NETAssemblyTypeAccelerators String[]
- Fully-qualified type names to expose as PowerShell type accelerators.
- NETConfiguration String
- .NET build configuration.
- Possible values:
Release,Debug - NETFramework String[]
- .NET target frameworks to build.
- NETHandleAssemblyWithSameName SwitchParameter
- Handle assemblies with the same name during import.
- NETProjectName String
- Project name for binary-module builds.
- NETProjectPath String
- Path to the owned .NET project for binary-module builds.
- Profile ModuleBuildProfileKind
- Named profile to emit.
- Possible values:
Standard,Binary - RequiredEncoding FileConsistencyEncoding
- Required encoding for file consistency checks.
- Possible values:
ASCII,UTF8,UTF8BOM,Unicode,BigEndianUnicode,UTF7,UTF32 - RequiredLineEnding FileConsistencyLineEnding
- Required line endings for file consistency checks.
- Possible values:
CRLF,LF - ResolveBinaryConflicts SwitchParameter
- Resolve binary dependency conflicts.
- ResolveBinaryConflictsName String
- Project name used when resolving binary dependency conflicts.
- SignIncludeBinaries SwitchParameter
- When signing is enabled, include binary files.
- SignIncludeExe SwitchParameter
- When signing is enabled, include executable files.
- SignIncludeInternals SwitchParameter
- When signing is enabled, include internal scripts.
- SignModule Boolean
- Enable signing for the built module.
- SkipBuiltinReplacements SwitchParameter
- Skip built-in placeholder replacements during build.
- SyncExternalHelpToProjectRoot Boolean
- Sync generated external help back to the project root.
- Validation Boolean
- Enable module validation defaults.
- VersionedInstallKeep Int32
- Number of installed versions to keep.
- VersionedInstallStrategy InstallationStrategy
- Versioned install strategy.
- Possible values:
Exact,AutoRevision