very minor changes
This commit is contained in:
@@ -11,6 +11,7 @@ If ( $SFCOutput -contains 'Windows Resource Protection did not find any integrit
|
|||||||
# Run enhanced DISM for Windows 8 and higher endpoints
|
# Run enhanced DISM for Windows 8 and higher endpoints
|
||||||
If ( IsWindowsVersion -ge "6.2" )
|
If ( IsWindowsVersion -ge "6.2" )
|
||||||
{
|
{
|
||||||
|
# Record start of DISM repair
|
||||||
$BeginDISMRun = (Get-Date)
|
$BeginDISMRun = (Get-Date)
|
||||||
|
|
||||||
Write-Output "Beginning repair of Windows Component Store"
|
Write-Output "Beginning repair of Windows Component Store"
|
||||||
@@ -19,9 +20,10 @@ If ( IsWindowsVersion -ge "6.2" )
|
|||||||
Write-Output "Beginning cleanup of superceded components in Windows Component Store"
|
Write-Output "Beginning cleanup of superceded components in Windows Component Store"
|
||||||
Start-Process "dism.exe" -ArgumentList "/online /cleanup-image /startcomponentcleanup" -Wait
|
Start-Process "dism.exe" -ArgumentList "/online /cleanup-image /startcomponentcleanup" -Wait
|
||||||
|
|
||||||
$EndDISMRun = $(Get-Date).AddSeconds(1)
|
# Record end of DISM repair
|
||||||
|
$EndDISMRun = (Get-Date)
|
||||||
|
|
||||||
# Adding results of DISM log file to this log file
|
# Extract results of DISM repair from system log and add them to this log
|
||||||
Write-Output "Beginning Windows Component Store log data collection"
|
Write-Output "Beginning Windows Component Store log data collection"
|
||||||
Get-Content -Path "${Env:WinDir}\Logs\DISM\dism.log" | Select-String -Pattern '^(\d{4})-(\d{2})-(\d{2}) (\d{2}):(\d{2}):(\d{2})' |
|
Get-Content -Path "${Env:WinDir}\Logs\DISM\dism.log" | Select-String -Pattern '^(\d{4})-(\d{2})-(\d{2}) (\d{2}):(\d{2}):(\d{2})' |
|
||||||
ForEach-Object {
|
ForEach-Object {
|
||||||
|
|||||||
Reference in New Issue
Block a user