LinuxQuestions.org
Latest LQ Deal: Complete CCNA, CCNP & Red Hat Certification Training Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 02-08-2006, 08:53 AM   #1
sunpascal
Member
 
Registered: Jan 2005
Distribution: Debian
Posts: 104

Rep: Reputation: 15
clear screen on console logout


hi,
I was wondering, is it possible to automatically clear the screen when you logout from the console? It's a littel irratating to see the commands your typed after logout.
I was thinking of modifying some script (if this is how you do it in linux....)
 
Old 02-08-2006, 10:29 AM   #2
Wim Sturkenboom
Senior Member
 
Registered: Jan 2005
Location: Roodepoort, South Africa
Distribution: Slackware 10.1/10.2/12, Ubuntu 12.04, Crunchbang Statler
Posts: 3,786

Rep: Reputation: 282Reputation: 282Reputation: 282
Have you tried something in a script called .bash_logout?

google search
 
Old 02-09-2006, 01:43 AM   #3
sunpascal
Member
 
Registered: Jan 2005
Distribution: Debian
Posts: 104

Original Poster
Rep: Reputation: 15
sorry, I can't find information of where to put that file.
Also, if I put it in my home dir doesn't in only affect one user? How do I make it global?
 
Old 02-09-2006, 01:47 AM   #4
bl0tt0
Member
 
Registered: Aug 2005
Location: The Glorious People's Republic of Austin
Posts: 156

Rep: Reputation: 26
why not just type
Code:
clear && logout
 
Old 02-09-2006, 02:12 AM   #5
reddazz
LQ Guru
 
Registered: Nov 2003
Location: N. E. England
Distribution: Fedora, CentOS, Debian
Posts: 16,298

Rep: Reputation: 75
you could create an alias for exit or logout in .bashrc e.g.
Code:
alias exit="clear && logout"
an alternative is
Code:
alias exit="reset && logout"
 
Old 02-09-2006, 06:22 AM   #6
cs-cam
Senior Member
 
Registered: May 2004
Location: Australia
Distribution: Gentoo
Posts: 3,544
Blog Entries: 4

Rep: Reputation: 57
This can be done globally in /etc/issue as well.
 
Old 02-09-2006, 06:34 AM   #7
sunpascal
Member
 
Registered: Jan 2005
Distribution: Debian
Posts: 104

Original Poster
Rep: Reputation: 15
doing clear > /etc/issue worked.
thanks!
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
how do i replace the clear "clear screen" with the cls command thefedexguy SUSE / openSUSE 2 12-02-2005 06:02 PM
clear the console tamtam Programming 2 12-07-2004 06:34 PM
How do I get the screen to clear on logout? muxman Debian 1 12-02-2004 03:13 AM
how to clear screen in C ? indian Programming 3 10-01-2004 11:58 PM
Clearing the tty console screen on logout koyi Linux - General 8 07-30-2004 12:32 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 09:24 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration