functions/public/Push-ConfigType.ps1
function Push-ConfigType { [CmdletBinding()] param ( [Parameter(ValueFromPipeline = $true, Mandatory = $true)] [Hashtable] $hash, [Parameter(Position = 0, Mandatory = $true)] [String] $type ) $newHash = @{}; foreach ($key in $hash.keys) { $newHash.Add($key, $type) } $hash._type_ = $newHash return $hash } |