diff --git a/Makefile b/Makefile index f3cabf5..5a2e111 100644 --- a/Makefile +++ b/Makefile @@ -132,6 +132,7 @@ UPROGS=\ $U/_grind\ $U/_wc\ $U/_zombie\ + $U/_clear\ fs.img: mkfs/mkfs README $(UPROGS) mkfs/mkfs fs.img README $(UPROGS) diff --git a/user/clear.c b/user/clear.c new file mode 100644 index 0000000..d1e4e37 --- /dev/null +++ b/user/clear.c @@ -0,0 +1,11 @@ +#include "kernel/types.h" +#include "kernel/stat.h" +#include "user/user.h" + +int +main(void) +{ + write(1, "\e[1;1H\e[2J", 12); + + exit(0); +}