Overview of the templates used in this project, and how to use them.
- TODO: Document how to deploy installation script templates to a new SCCM application deployment.
Batch script to install the application. Any arguments should be specified directly after -FilePath.
powershell.exe -NoProfile -ExecutionPolicy Bypass -NoLogo -File .\Install-Application.ps1
Don't include the carets (^) in the actual script, they are used to indicate line continuation in batch files:
powershell.exe -NoProfile -ExecutionPolicy Bypass -NoLogo -File .\Install-Application.ps1 ^
-FilePath "C:\Path\To\Installer.msi" ^
-Arguments "/qn", "/foo"
PowerShell script to install the application and log to a standard location.
$LatestLog = Get-ChildItem -Path "C:\temp\Logs\Deployment\*.log" `
| sort LastWriteTime -Descending | Select-Object -First 1
Get-Content -Path $LatestLog.FullName | more