Skip to content

Commit

Permalink
Add some docs
Browse files Browse the repository at this point in the history
  • Loading branch information
PrzemyslawKlys committed Aug 14, 2024
1 parent d468acf commit 81c09a1
Showing 1 changed file with 29 additions and 0 deletions.
29 changes: 29 additions & 0 deletions Public/New-ConfigurationPlaceHolder.ps1
Original file line number Diff line number Diff line change
@@ -1,4 +1,33 @@
function New-ConfigurationPlaceHolder {
<#
.SYNOPSIS
Command helping define custom placeholders replacing content within a script or module during the build process.
.DESCRIPTION
Command helping define custom placeholders replacing content within a script or module during the build process.
It modifies only the content of the script or module (PSM1) and does not modify the sources.
.PARAMETER CustomReplacement
Hashtable array with custom placeholders to replace. Each hashtable must contain two keys: Find and Replace.
.PARAMETER Find
The string to find in the script or module content.
.PARAMETER Replace
The string to replace the Find string in the script or module content.
.EXAMPLE
New-ConfigurationPlaceHolder -Find '{CustomName}' -Replace 'SpecialCase'
.EXAMPLE
New-ConfigurationPlaceHolder -CustomReplacement @(
@{ Find = '{CustomName}'; Replace = 'SpecialCase' }
@{ Find = '{CustomVersion}'; Replace = '1.0.0' }
)
.NOTES
General notes
#>
[CmdletBinding(DefaultParameterSetName = 'FindAndReplace')]
param(
[Parameter(Mandatory, ParameterSetName = 'CustomReplacement')][System.Collections.IDictionary[]] $CustomReplacement,
Expand Down

0 comments on commit 81c09a1

Please sign in to comment.