Clear terminal history in Pydroid 3

175 Views Asked by At

I could not figure out how to clear Pydroid's terminal history.

I tried hictory -c and history -d and history -w and that does not work. Clear and cls are not available commands.

2

There are 2 best solutions below

0
Hassan Voyeau On BEST ANSWER

I figured where the history is stored in a file. The following commands worked for me. You must restart Pydroid to see the change.

/storage/emulated/0 $ cd ~
~/data/ru.iiec.pydroid3/app_HOME $ ls -a
.             ..            .ash_history
~/data/ru.iiec.pydroid3/app_HOME $ rm .ash_history
~/data/ru.iiec.pydroid3/app_HOME $
1
MASTER On

With the console

print("\033[H\033[J")