Set Windows to store UTC time

This commit is contained in:
Manuel Thalmann 2023-08-14 01:32:57 +02:00
parent ea97d2ebbd
commit ee9a796e1c
3 changed files with 7 additions and 2 deletions

View file

@ -3,6 +3,10 @@
. "$PSScriptRoot/../../../scripts/Windows/Scripts/Prerequisites.ps1";
. "$PSScriptRoot/../../../scripts/Windows/Scripts/Context.ps1";
function Initialize-Configuration {
Set-ItemProperty "HKLM:\SYSTEM\CurrentControlSet\Control\TimeZoneInformation" -Name "RealTimeIsUniversal" -Value 1 -Type "DWord";
}
Write-Host "Starting Restoration of Windows";
. "$PSScriptRoot/../../../scripts/Windows/OS/Install.ps1";
[Context]$context = [Context]::new();

View file

@ -77,7 +77,5 @@ $startLayout | Add-Member -NotePropertyName "primaryOEMPins" -NotePropertyValue
$startLayout | ConvertTo-Json -Compress | Set-Content "$env:SystemDrive\Users\Default\AppData\Local\Microsoft\Windows\Shell\LayoutModification.json";
Write-Information "Copy Region & Language Settings to System Configuration";
Pop-Location;
Remove-Item -Recurse "$tempDir";

View file

@ -11,6 +11,9 @@ function Invoke-WindowsInstallation([Context] $context)
$softwarePath = "$PSScriptRoot/../Software";
if (-not $context.Get("InitialConfiguration")) {
if ((Get-Command Initialize-Configuration -ErrorAction SilentlyContinue)) {
Initialize-Configuration $context;
}
$null = Enable-WindowsOptionalFeature -Online -All -FeatureName "NetFx3";