tags:

views:

83

answers:

1

I know that you should be able to search in Screen by

C-a /

or

C-a ?

or

C-a s

or

C-a r

However, none of the commands work for me. I have the following .screenrc.

My .screenrc

markkeys h=d:j=h:k=t:l=n

# to change the escape key from ^Aa to 
# NB ^n to move btw Screens
escape ^Tt

# I want to use Vim's navigation keys
bind h focus down 
bind t focus up

### Keybindings# {{{

# to disable xoff
bind s

# remove some key bindings                                                                                                                                                                                    
bind W
#bind ^\
#bind \\
bind ^h

# same as C-a "
bind 'W' windowlist

How can you search effectively in Screen, such that you get all matches colored?

+1  A: 

You have to enter copy mode first (by pressing C-a [). In copy mode, press / to search forward (and then type what to search for, then press Enter), or ? to search backward. Press Enter twice to exit copy mode.

pts
@pts: Thank you for your answer! I clarified the question slightly. It would be great to see all matches colored.
Masi
I guess screen doesn't have this search result highlight feature. If you have a preferred text editor or web browser with tat feature, you can dump the copy buffer to file, and then use your editor or browser to search in the file. From the screen man page: to the screen-exchange file (/tmp/screen-exchange per default) once copy-mode is finished. This example demonstrates how to dump the whole scrollback buffer to that file: "C-A [ g SPACE G $ >".
pts