2 * VER.C - ver internal command.
8 * rewrote ver command to accept switches, now ver alone prints
9 * copyright notice only.
11 * 27-Jul-1998 (John P Price <linux-guru@gcfl.net>)
12 * added config.h include
14 * 30-Jul-1998 (John P Price <linux-guru@gcfl.net>)
15 * added text about where to send bug reports and get updates.
17 * 20-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
18 * Unicode and redirection safe!
20 * 26-Feb-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
21 * New version info and some output changes.
35 VOID
ShortVersion (VOID
)
43 #ifdef INCLUDE_CMD_VER
46 * display shell version info internal command.
50 INT
cmd_ver (LPTSTR cmd
, LPTSTR param
)
54 if (_tcsstr (param
, _T("/?")) != NULL
)
56 ConOutPuts (_T("Displays shell version information\n"
60 " /C Displays credits.\n"
61 " /R Displays redistribution information.\n"
62 " /W Displays warranty information."));
70 "Copyright (C) 1994-1998 Tim Norman and others."));
71 ConOutPuts (_T("Copyright (C) 1998-2000 Eric Kohl and others."));
73 /* Basic copyright notice */
74 if (param
[0] == _T('\0'))
76 ConOutPuts (_T("\n"SHELLINFO
77 " comes with ABSOLUTELY NO WARRANTY; for details\n"
78 "type: `ver /w'. This is free software, and you are welcome to redistribute\n"
79 "it under certain conditions; type `ver /r' for details. Type `ver /c' for a\n"
80 "listing of credits."));
84 for (i
= 0; param
[i
]; i
++)
87 if (param
[i
] == _T(' '))
90 if (param
[i
] == _T('/'))
92 /* is this a lone '/' ? */
93 if (param
[i
+ 1] == 0)
95 error_invalid_switch (_T(' '));
101 if (_totupper (param
[i
]) == _T('W'))
103 /* Warranty notice */
104 ConOutPuts (_T("\n This program is distributed in the hope that it will be useful,\n"
105 " but WITHOUT ANY WARRANTY; without even the implied warranty of\n"
106 " MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n"
107 " GNU General Public License for more details."));
109 else if (_totupper (param
[i
]) == _T('R'))
111 /* Redistribution notice */
112 ConOutPuts (_T("\n This program is free software; you can redistribute it and/or modify\n"
113 " it under the terms of the GNU General Public License as published by\n"
114 " the Free Software Foundation; either version 2 of the License, or\n"
115 " (at your option) any later version."));
117 else if (_totupper (param
[i
]) == _T('C'))
119 /* Developer listing */
121 "FreeDOS version written by:\n"
122 " Tim Norman Matt Rains\n"
123 " Evan Jeffrey Steffen Kaiser\n"
124 " Svante Frey Oliver Mueller\n"
125 " Aaron Kaufman Marc Desrochers\n"
126 " Rob Lake John P Price\n"
129 "ReactOS version written by:\n"
130 " Eric Kohl Emanuele Aliberti\n"
131 " Paolo Pantaleo\n"));
135 error_invalid_switch ((TCHAR
)_totupper (param
[i
]));
142 "Send bug reports to <ekohl@rz-online.de>.\n"
143 "Updates are available at: http://www.reactos.com"));