File tree Expand file tree Collapse file tree 2 files changed +31
-14
lines changed
Expand file tree Collapse file tree 2 files changed +31
-14
lines changed Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1+ @ echo off
2+ SETLOCAL EnableDelayedExpansion
3+ for /F " tokens=1,2 delims=#" %%a in ('" prompt #$H#$E# & echo on & for %%b in (1) do rem" ') do (
4+ set " DEL = %%a "
5+ )
6+ rem echo say the name of the colors, don't read
7+ :start
8+ rem cls
9+
10+ call :ColorText 0e " 同步开始"
11+ echo .
12+ net stop w32time
13+ net start w32time
14+ w32tm /config /manualpeerlist:" time.nist.gov" /syncfromflags:manual /reliable:yes /update
15+ w32tm /resync
16+ w32tm /resync
17+ w32tm /config /manualpeerlist:" time.windows.com" /syncfromflags:manual /reliable:yes /update
18+ w32tm /resync
19+ w32tm /resync
20+ call :ColorText 0e " 同步结束"
21+ echo .
22+ pause
23+
24+ goto :eof
25+
26+ :ColorText
27+ echo off
28+ < nul set /p " . = %DEL% " > " %~2 "
29+ findstr /v /a:%1 /R " ^$" " %~2 " nul
30+ del " %~2 " > nul 2 >& 1
31+ goto :eof
You can’t perform that action at this time.
0 commit comments