cliProxy icon indicating copy to clipboard operation
cliProxy copied to clipboard

Command history is lost when using "clear" command in terminal

Open vcwygir opened this issue 2 years ago • 1 comments

Hello,

I have noticed that some command history is lost when I use the clear command in my terminal. Can you explain why this is happening?

Thank you.

vcwygir avatar Jan 10 '24 07:01 vcwygir

Hey there!

What I suspect is happening is that all input and output is written to a file, as in their raw bytes, including control characters. When you cat the results, the terminal renders all text in the file including control characters, so it appears you've lost data. If you examine the file with xxd or in a text editor it may still be there.

djhohnstein avatar Jan 12 '24 17:01 djhohnstein