Unix has a useful command named 'uptime'. Of course, it tells you how long your computer has been running.
Windows doesn't have that command per se though it does have various ways to get the same info. But I don't want to use those, I just want 'uptime'. I used to have a binary .exe that did that, but no more.
This workaround gets you pretty much there:
That should get you a one-line script that runs "psinfo", but only displays the uptime line.
Windows doesn't have that command per se though it does have various ways to get the same info. But I don't want to use those, I just want 'uptime'. I used to have a binary .exe that did that, but no more.
This workaround gets you pretty much there:
- download PsTools.
- from the zip, you could just run psinfo. It gives you several pieces of information including the uptime.
- or if you really want to be pedantic about it, create a one-line script with this command very carefully typed:
echo @psinfo ^| find "Uptime:" > uptime.cmd
That should get you a one-line script that runs "psinfo", but only displays the uptime line.
--
Furry cows moo and decompress.
Furry cows moo and decompress.