RSS

Fixing delete button on a Mac terminal

12 Jun

I do all my web development ssh-ing to a Linux box. On my server the Mac ‘delete’ button worked fine in shell, but was deleting forward in Vim.

Here’s a fix!

Run a command in your terminal window:

stty -a | grep erase

and check if it says

erase = ^?;

If it is set to something else (e.g. ^H) then put the following line in both .bashrc and in either .bash_profile or /etc/profile:

  if tty --quiet ; then
    stty erase '^?'
  fi

Good luck!

Taken from http://www.ibb.net/~anne/keyboard.html

Advertisements
 
Leave a comment

Posted by on June 12, 2007 in Mac OS

 

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

 
%d bloggers like this: