aosp12/external/toybox/toys/other/clear.c

20 lines
284 B
C

/* clear.c - clear the screen
*
* Copyright 2012 Rob Landley <rob@landley.net>
USE_CLEAR(NEWTOY(clear, NULL, TOYFLAG_USR|TOYFLAG_BIN))
config CLEAR
bool "clear"
default y
help
Clear the screen.
*/
#include "toys.h"
void clear_main(void)
{
printf("\033[2J\033[H");
}