Ãâó http://www.garrettgalloway.com/index.php?p=projects&e=7
Here's the source (VS2013) zip: watch.zip (14KB).
Here's the compiled executable, requires .NET 4.5: watch.exe (13KB)
watch.exe ÆÄÀÏ C:\Windos Æú´õ·Î ´Ù¿î·Îµå
Example)
C:\>watch /n 5 "netstat -an |findstr ESTABLISHED"
C:\>watch /n 10 "watch /n 10 "route PRINT -4"
C:\Users\Administrator>watch /?
watch Copyright (c) Garrett Galloway 2014.
Usage:
watch [/n <seconds>] [/m <executions>] [/h] <command + args>
/n <seconds> Wait time in seconds between <command + args>. Default: 2.
/m <executions> Max number of executions. Default: Unlimited.
/? Display this help text.
Example: watch /n 4 "dir c:\windows"