1 /* $Id: echo.c,v 1.3 1999/10/03 22:15:33 ekohl Exp $
3 * ECHO.C - internal echo commands.
8 * 16 Jul 1998 (Hans B Pufal)
11 * 16 Jul 1998 (John P Price)
12 * Separated commands into individual files.
14 * 27-Jul-1998 (John P Price <linux-guru@gcfl.net>)
15 * Added config.h include
17 * 08-Dec-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
18 * Added help text ("/?").
20 * 19-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
21 * Unicode and redirection ready!
34 INT
CommandEcho (LPTSTR cmd
, LPTSTR param
)
37 DebugPrintf ("CommandEcho '%s' : '%s'\n", cmd
, param
);
40 if (!_tcsncmp (param
, _T("/?"), 2))
42 ConOutPuts ("Displays a message or switches command echoing on or off.\n\n"
43 "ECHO [ON | OFF]\nECHO [message]\n\n"
44 "Type ECHO without a parameter to display the current ECHO setting.");
48 if (_tcsicmp (param
, D_OFF
) == 0)
50 else if (_tcsicmp (param
, D_ON
) == 0)
55 ConOutPrintf (_T("ECHO is %s\n"), bEcho
? D_ON
: D_OFF
);
60 INT
CommandEchos (LPTSTR cmd
, LPTSTR param
)
63 DebugPrintf ("CommandEchos '%s' : '%s'\n", cmd
, param
);
66 if (!_tcsncmp (param
, _T("/?"), 2))
68 ConOutPuts ("Display a messages without trailing carridge return and line feed.\n"
75 ConOutPrintf ("%s", param
);
81 INT
CommandEchoerr (LPTSTR cmd
, LPTSTR param
)
84 DebugPrintf ("CommandEchoerr '%s' : '%s'\n", cmd
, param
);
87 if (!_tcsncmp (param
, _T("/?"), 2))
89 ConOutPuts ("Displays a message to the standard error.\n"
101 INT
CommandEchoserr (LPTSTR cmd
, LPTSTR param
)
104 DebugPrintf ("CommandEchoserr '%s' : '%s'\n", cmd
, param
);
107 if (!_tcsncmp (param
, _T("/?"), 2))
109 ConOutPuts ("Prints a messages to standard error output without trailing carridge return and line feed.\n"
111 "ECHOSERR message\n");
116 ConOutPrintf ("%s", param
);