Clear Bash History On Linux

English

Clear bash history on Linux.

If you don't want others to be able to see what commands you have used, then you would want to clear the history of all commands.

Clear bash history on Linux.

Run the following commands from a terminal window:

cat /dev/null > ~/.bash_history && history -c && exit

Press Enter.

What do these 3 commands do?

  • The 'cat' command empties the .bash_history file of the currently logged in user.
  • The 'history -c' command cleans the history of the current user session.
  • The 'exit' command quits the current session.
Tags: 
Library categories: 

Games For Linux

Windows has always been the preferred platform for gaming, but after STEAM's interest in Linux more game developers are making their games natively available for Linux.

Disclaimer

All information on this website is published in good faith and for general educational purposes and for use in safe testing environments only. While linuxexperten.com strives to make the information on this site as accurate as possible, linuxexperten.com does not warrant its completeness, reliability and accuracy.

We are not responsible for any losses or damages associated with the use of our website. While we strive to provide only links to useful websites, we have no control over the content of these sites and links to other sites do not constitute a recommendation for all content contained on these websites.

 

Site Information

This is a professional review site that receives compensation from the companies whose products reviewed. Each service or product are thoroughly tested and given high marks if considered to be the very best. Independently owned and the opinions expressed here are no one elses.

 

Limited Time Offers

Coming soon...