Orge
8. November 2024 um 12:08
1
Hallo!
Anfängerfrage: Bei einem Paket aus dem Depot (Zoom) ergänzen wir bisher manuell zwei Registryeinträge in der Empirum-Setup.inf. Wie mache ich das mit der Produktautomatisierung?
Viele Grüße
Orge
Moin @Orge
hierfür kann ich das CustomSkript empfehlen:
<#
.SYNOPSIS
Add content to a custom function.
.DESCRIPTION
Adds content to a custom function in a Deploy-Application.ps1 file.
The position of the content can be specified to be at the beginning or end of the custom function.
If the custom function is not found or any of the specified content is not valid PowerShell code, an error is thrown.
The content can be specified as a string or as a file containing the content.
.PARAMETER DeployApplicationFile
The Deploy-Application.ps1 file.
.PARAMETER Content
The content to add to the custom function. Must be valid PowerShell script.
.PARAMETER ContentFile
The file containing the content to add to the custom function. Must be valid PowerShell script.
.PARAMETER FunctionName
The name of the custom function to add content to.
.PARAMETER InsertAtEnd
Insert the content at the end of the custom function. Default is to insert at the beginning.
.EXAMPLE
Add-ContentToCustomFunction -DeployApplicationFile '$PWD\Deploy-Application.ps1' -Content 'Write-Host "Hello, World!"' -FunctionName 'CustomBegin' -InsertAtEnd
Diese Datei wurde abgeschnitten. Original zeigen