screen-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: how to kill some borked elements in screen


From: Dan Mahoney, System Admin
Subject: Re: how to kill some borked elements in screen
Date: Thu, 28 May 2009 18:29:08 -0400 (EDT)
User-agent: Alpine 2.00 (BSF 1167 2008-08-23)

On Thu, 28 May 2009, Chris Jones wrote:

On Thu, May 28, 2009 at 12:38:51PM EDT, Dan Mahoney, System Admin wrote:
On Thu, 28 May 2009, Albert Vilella wrote:

Hi,

I've got a screen session with about a dozen of terminals, and a
couple of them are basically unresponsive.  I can navigate to them in
screen, but they don't respond. Is there a way to kill them or hide
them so that they don't show up when navigating down to all my
terminals?

Ctrl-a K, when on the unresponsive screen, or ctrl-a, :kill [enter].

The manpage says this:

Note: Emacs users should keep this command in mind, when killing a
line.  It is recommended not to use "C-a" as the screen escape key or
to rebind kill to "C-a K".

Well, actually the built-in default mapping for the "kill" command
appears to be:

Ctrl-a Ctrl-k

If you are in a shell that uses emacs-style keybindings and type some
command at the prompt you could issue a Ctrl-a to make the cursor move
to the beginning of the line and follow up with a Ctrl-k to delete to
the end of the line.

With the default key bindings, gnu/screen would intercept this sequence
and bring up the "Really kill this window y/n" prompt.

The way to work around this issue as recommended by the manual is either
not to use Ctrl-a as your screen escape key or to rebind kill to
something else, such as "Shift-k".

But that is what it came bound to by default on my system.  Perhaps
outdated docs?

Possibly because your .screenrc has something like this:

# remove dangerous keybindings
bind ^k                 # bind Ctrl-k to nothing

# replace them with safer ones
bind 'K' kill           # bind Shift-k to kill command

If I am guessing correctly, this may be because the screenrc templates
that ship with screen usually have such bind commands?

So the screenrc that ships cancels out the built in (and dangerous) mapping. Why have it in in the first place then?

My screen ctrl-a ? shows that both k and K are kill -- is this the same for you? If so, where's it defined?

Also, wordwise:

It is recommended not to use

would be clearer as:

It is recommended to either not use

as the "not" confused me on initial read.

-Dan

--

"We need another cat.  This one's retarded."

-Cali, March 8, 2003 (3:43 AM)

--------Dan Mahoney--------
Techie,  Sysadmin,  WebGeek
Gushi on efnet/undernet IRC
ICQ: 13735144   AIM: LarpGM
Site:  http://www.gushi.org
---------------------------





reply via email to

[Prev in Thread] Current Thread [Next in Thread]