XINU
xsh_clear.c
Go to the documentation of this file.
1 
5 #include <xinu.h>
6 #include <stdio.h>
7 
18 shellcmd xsh_clear(int nargs, char *args[])
19 {
20 
21  /* Insure no arguments were passed */
22 
23  if (nargs > 1)
24  {
25  fprintf(stderr, "use is: %s\n", args[0]);
26  return 1;
27  }
28 
29  printf("\033[0m\033[2J\033[H\n");
30  return 0;
31 }
全てのシステムヘッダファイルをインクルードする。
#define stderr
Definition: stdio.h:17
int32 printf(const char *,...)
Definition: printf.c:13
shellcmd xsh_clear(int nargs, char *args[])
ディスプレイウィンドウをクリアする(xtermやVT100を想定している)
Definition: xsh_clear.c:18
int32 shellcmd
シェルコール関数 返り値の型
Definition: kernel.h:51
int32 fprintf(int, char *,...)
Definition: fprintf.c:14