diff --git a/Windows-Scripts/windows-repair.ps1 b/Windows-Scripts/windows-repair.ps1 index 584730a..f8b556d 100644 --- a/Windows-Scripts/windows-repair.ps1 +++ b/Windows-Scripts/windows-repair.ps1 @@ -74,20 +74,19 @@ if (-not ([Security.Principal.WindowsIdentity]::GetCurrent().Groups -contains 'S .............. '@ # vars - $LogDir = "$env:USERPROFILE\Downloads\Repair-Log-$((Get-Date).ToString('yyyy-MM-dd-HHmm'))" # path to new log Dir - $MainLog = "$LogDir\main.log" # error log file - Write-Host "FIXING WINDOWS FULL PRINCESS PI STYLE (THIS WILL TAKE MANY HOURS AND REBOOT MORE THAN ONCE, SLOWLY)`n" -ForegroundColor Magenta Write-Host "Creating Log Dir at $LogDir 1/21 at $((Get-Date).ToString('yyyy-MM-dd-HHmm'))" | Tee-Object -FilePath "$MainLog" -Append - New-Item -Path "$LogDir" -ItemType Directory > $null 2>> "$MainLog" # create log dir + mkdir "$LogDir" > $null 2> $null # create log dir + $LogDir = "$env:USERPROFILE\Downloads\Repair-Log-$((Get-Date).ToString('yyyy-MM-dd-HHmm'))" # path to new log Dir + + Write-Host "Initialize Log File $LogFile 3/21 at $((Get-Date).ToString('yyyy-MM-dd-HHmm'))" | Tee-Object -FilePath "$MainLog" -Append + echo "$((Get-Date).ToString('yyyy-MM-dd-HHmm'))" >> "LogDir\main.log" + $MainLog = "$LogDir\main.log" # error log file Write-Host "Opening Log Dir 2/21 at $((Get-Date).ToString('yyyy-MM-dd-HHmm'))" | Tee-Object -FilePath "$MainLog" -Append explorer.exe "$LogDir" - Write-Host "Initialize Log File $LogFile 3/21 at $((Get-Date).ToString('yyyy-MM-dd-HHmm'))" | Tee-Object -FilePath "$MainLog" -Append - Write-Host "$((Get-Date).ToString('yyyy-MM-dd-HHmm'))" >> "$MainLog" - Write-Host "ABORTING ANY SCHEDULED SHUTDOWN 4/21 AT $((Get-Date).ToString('yyyy-MM-dd-HHmm'))" | Tee-Object -FilePath "$MainLog" -Append shutdown.exe /a > $null 2>> "$MainLog" # cmd abort scheduled shutdowns