Patch-ID: bash32-032
[bash.git] / examples / loadables / necho.c
blob521ee2c6df950f845e7c798db1b969cacfce3d15
1 /* necho - echo without options or argument interpretation */
3 /* Sample builtin to be dynamically loaded with enable -f and replace an
4 existing builtin. */
6 #include <stdio.h>
7 #include "builtins.h"
8 #include "shell.h"
10 necho_builtin (list)
11 WORD_LIST *list;
13 print_word_list (list, " ");
14 printf("\n");
15 fflush (stdout);
16 return (EXECUTION_SUCCESS);
19 char *necho_doc[] = {
20 "Print the arguments to the standard ouput separated",
21 "by space characters and terminated with a newline.",
22 (char *)NULL
25 struct builtin necho_struct = {
26 "echo",
27 necho_builtin,
28 BUILTIN_ENABLED,
29 necho_doc,
30 "echo [args]",