5

I have installed Ubuntu 10.04. It works fine, but when I press Ctrl-C in gnome-terminal I get:

user@desktop:~$ ^C
user@desktop:~$ ^C
user@desktop:~$

In Ubuntu 9.04 (I did have it before) it was so:

user@desktop:~$ 
user@desktop:~$ 
user@desktop:~$

Who knows how can I fix this?

1
  • i expect, best case, this is due to an obscure bash (or possibly gconf) setting; medium case, this is due to some tweak in a terminfo file; worst case, you'll have to patch code and recompile your bash or gnome-terminal packages. May 3, 2010 at 16:40

3 Answers 3

4

Give this a try, it will affect other control characters, too:

stty -echoctl
5
  • 1
    Dennis, thanks a lot. It works. But when I close gnome-terminal and run it again this parametr is on. How can I save it?
    – sev
    May 3, 2010 at 18:26
  • @sev: Add that command to your ~/.bashrc file. May 3, 2010 at 19:26
  • You should make that only run when you're on a terminal, with something like: [ -t 1 ] && stty -echoctl
    – NVRAM
    May 4, 2010 at 0:16
  • @NVRAM: I'm curious what the downside is. Besides, normally ~/.bashrc is only loaded for interactive shells. May 4, 2010 at 0:31
  • Hmm, I think you're right. If it's in ~/.bashrc rather than ~/.profile or ~/.bash_profile -- it would be good to add that to the answer. While it would probably not kill the job (just print an unneeded error) it's a habit I picked up using Bourne and K-shells -- to avoid interactive commands for when the profile was run by cron or at jobs.
    – NVRAM
    May 7, 2010 at 15:44
0

you can also highlight and use right click on systems you access but don't want to or have time to change settings.

0

You just have to hold the Shift key down as well. So instead of just Ctrl + C, you do Shift + Ctrl + C.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .