Version 1.0.0 Release #1

Merged
Torsten merged 7 commits from dev into main 2026-04-21 13:52:34 +00:00
3 changed files with 6 additions and 6 deletions
Showing only changes of commit 59d884c061 - Show all commits

View File

@@ -7,7 +7,7 @@
Description = "Merges DSC configuration data from templates and deployment data." Description = "Merges DSC configuration data from templates and deployment data."
PowerShellVersion = "5.1" PowerShellVersion = "5.1"
FunctionsToExport = @( FunctionsToExport = @(
"Merge-ConfigurationData" "Merge-DSCConfigurationData"
) )
CmdletsToExport = @() CmdletsToExport = @()
VariablesToExport = @() VariablesToExport = @()

View File

@@ -9,5 +9,5 @@ foreach($File in @($Private + $Public)){
} }
Export-ModuleMember -Function @( Export-ModuleMember -Function @(
"Merge-ConfigurationData" "Merge-DSCConfigurationData"
) )

View File

@@ -1,4 +1,4 @@
function Merge-ConfigurationData { function Merge-DSCConfigurationData {
[CmdletBinding()] [CmdletBinding()]
Param( Param(
[Parameter(Mandatory=$true)] [Parameter(Mandatory=$true)]
@@ -21,7 +21,7 @@ function Merge-ConfigurationData {
Write-Verbose "Key [$($Property.Name)] is a Hashtable" Write-Verbose "Key [$($Property.Name)] is a Hashtable"
if($null -ne $Deployment.$($Property.Name)){ if($null -ne $Deployment.$($Property.Name)){
Write-Verbose "Key [$($Property.Name)] is present in Deployment Data" Write-Verbose "Key [$($Property.Name)] is present in Deployment Data"
$Output.($Property.Name) = Merge-ConfigurationData -Template $Template.$($Property.Name) -Deployment $Deployment.$($Property.Name) -Output $Output.$($Property.Name) $Output.($Property.Name) = Merge-DSCConfigurationData -Template $Template.$($Property.Name) -Deployment $Deployment.$($Property.Name) -Output $Output.$($Property.Name)
}else{ }else{
Write-Verbose "Key [$($Property.Name)] is not present in Deployment Data" Write-Verbose "Key [$($Property.Name)] is not present in Deployment Data"
$Output.Add($($Property.Name),(Copy-ConfigurationDataValue -Value $Template.$($Property.Name))) $Output.Add($($Property.Name),(Copy-ConfigurationDataValue -Value $Template.$($Property.Name)))
@@ -30,7 +30,7 @@ function Merge-ConfigurationData {
Write-Verbose "Key [$($Property.Name)] is a Ordered Dictionary" Write-Verbose "Key [$($Property.Name)] is a Ordered Dictionary"
if($null -ne $Deployment.$($Property.Name)){ if($null -ne $Deployment.$($Property.Name)){
Write-Verbose "Key [$($Property.Name)] is present in Deployment Data" Write-Verbose "Key [$($Property.Name)] is present in Deployment Data"
$Output.($Property.Name) = Merge-ConfigurationData -Template $Template.$($Property.Name) -Deployment $Deployment.$($Property.Name) -Output $Output.$($Property.Name) $Output.($Property.Name) = Merge-DSCConfigurationData -Template $Template.$($Property.Name) -Deployment $Deployment.$($Property.Name) -Output $Output.$($Property.Name)
}else{ }else{
Write-Verbose "Key [$($Property.Name)] is not present in Deployment Data" Write-Verbose "Key [$($Property.Name)] is not present in Deployment Data"
$Output.Add($($Property.Name),(Copy-ConfigurationDataValue -Value $Template.$($Property.Name))) $Output.Add($($Property.Name),(Copy-ConfigurationDataValue -Value $Template.$($Property.Name)))
@@ -71,7 +71,7 @@ function Merge-ConfigurationData {
if($MatchingDeploymentItems.Count -gt 0){ if($MatchingDeploymentItems.Count -gt 0){
foreach($DeploymentItem in $MatchingDeploymentItems){ foreach($DeploymentItem in $MatchingDeploymentItems){
$OutputItem = @($Output.$($Property.Name) | Where-Object { Test-ConfigurationDataItemKeyMatch -Left $_ -Right $DeploymentItem -KeyNames $SearchKeyNames })[0] $OutputItem = @($Output.$($Property.Name) | Where-Object { Test-ConfigurationDataItemKeyMatch -Left $_ -Right $DeploymentItem -KeyNames $SearchKeyNames })[0]
Merge-ConfigurationData -Template $TemplateItem.Value -Deployment $DeploymentItem -Output $OutputItem | Out-Null Merge-DSCConfigurationData -Template $TemplateItem.Value -Deployment $DeploymentItem -Output $OutputItem | Out-Null
} }
}else{ }else{
if($TemplateItem.IsWildcard){ if($TemplateItem.IsWildcard){