Done Suggestion for TCC 'ver' command

Jan 28, 2020
6
0
May I suggest a change for the output of TCC's ver command?

Currently it displays TCC version info before Windows version info.

TCC 25.00.27 x64 Windows 10 [Version 10.0.18362.592]
The "standard" Windows ver command just outputs

Microsoft Windows [Version 10.0.18362.592]
I was running a batch file that worked fine under CMD but broke because of this difference. It would have worked if the Windows version info was output prior to TTC version info e.g. something like

Windows 10 [Version 10.0.18362.592] TCC 25.00.27 x64
Just a thought and no big deal. It's just a minor incompatibility thing likely specific to me!
 
I think this is almost what is wanted;
Code:
e:\utils>echo Microsoft Windows %_dosver [Version %_winver.%_osbuild] TCC %_4ver.%_build %@if[%_x64 eq 1,x64,x32]
Microsoft Windows 10.0 [Version 10.0.18362] TCC 25.00.27 x64
Just missing the Windows minor version.

Joe
 
May 20, 2008
10,634
82
Syracuse, NY, USA
Code:
set _ubr=`%@regquery["HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\UBR"]`
I don't believe there is any official, non-hackey of getting this info.
The same goes for the Windows release ID.
Code:
v:\> set _winrelease=`%@regquery["HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ReleaseId"]`

v:\> echo %_winrelease
1909
Since getting any of the info talked about recently is an easy one-liner, I don't see the need for several new internal variables.
 
Aug 23, 2010
588
7
Unfortunately, all of the registry keys can be easily falsified.
There's no way to know real Windows version from OS itself via API anymore. All the relevant calls are outright lying to the applications.
 
Oct 18, 2009
351
17
I think most of the time when folks type VER we're looking for the TCC version, not the Windows version.

However, possible changes would be:

VER returns the windows version, like CMD, and these options are available. (I had to add ... because the editor won't take multiple spaces.)

VER /T ... (for VER /TCC)
VER /F ... (for VER /FULL)
VER /B ... (for VER /BOTH)

-or-
VER /W ... (for VER /Windows version only)
VER /C ... (for VER /mimic CMD)