Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I love using history from the command line to keep track of commands but I find its list to be a bit too short for my liking. Is there any way to change this?

share|improve this question

migrated from stackoverflow.com Jan 7 '11 at 20:01

This question came from our site for professional and enthusiast programmers.

2 Answers 2

You can increase the size of the history buffer by typing set history=100. If you put this in your ~/.bashrc then it will remain permanent.

share|improve this answer
2  
here is no .bashrc on OS X by default. I suggest .bash_profile instead. –  Daniel Beck Jan 7 '11 at 20:09

In your ~/.bash_profile file, export the HISTSIZE variable to the desirable number of entries to save:

export HISTSIZE=5000
share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.