[feature] script to add schedule task for wsl time sync

This commit is contained in:
Klesh Wong 2021-07-22 12:30:21 +08:00
parent 72a181fcf5
commit 689dea344d

View File

@ -0,0 +1,2 @@
schtasks /create /tn WSLClockSync /tr "wsl.exe sudo hwclock -s" /sc onevent /ec system /mo "*[System[Provider[@Name='Microsoft-Windows-Kernel-General'] and (EventID=1)]]"
Set-ScheduledTask WSLClockSync -Settings (New-ScheduledTaskSettingsSet -AllowStartIfOnBatteries)