Pages

Monday, August 10, 2009

Clearing the screen after bash logout in linux

From the 'To stupid to anyone´s care about writing this down...' there´s a way to clear the screen just after you logout of a linux shell...  After looking around hard, I found this tip from a newsgroup archive.
Edit the /etc/profile file adding at the top of the file:
    trap clear 0
This will clear the console screen irrespective of which VT that's in use or who's using it. It's just a single entry in one file. And if you have a configured /etc/issue file configured it will display it.