Help - Search - Members - Calendar
Full Version: how do you turn on history?
The Planet Forums > Operating Systems > BSD > BSD HOWTOs
Clark
With RH you use the up and down arrows to get most recently used commands. How do you do this with freebsd?
smoker
Which shell are you using ?
CODE
env

It should work ok as root, but not with other shells. (bourne for one)
The default shell for users is sh while default for root is csh.
Check your $home directory for .cshrc or .bashrc and it can be specified in there.

Here is a snippet of my .cshrc (FBSD 4.7)

CODE
if ($?prompt) then

       # An interactive shell -- set some stuff up

       set prompt = "`hostname -s`# "

       set filec

       set history = 100

       set savehist = 100

       set mail = (/var/mail/$USER)

       if ( $?tcsh ) then

               bindkey "^W" backward-delete-word

               bindkey -k up history-search-backward

               bindkey -k down history-search-forward

       endif

endif


Or have a look in the handbook http://www.freebsd.org/doc/en_US.ISO8859-1...books/handbook/ or here http://www.uwizone.com/unix-basics.shtml

alan
Clark
Thank you. I didn't even realize I wasn't root! :eek:
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2009 Invision Power Services, Inc.