Re: command to clear screen buffer?

Konstantin Svist <[email protected]>
Newsgroups gmane.comp.gnu.screen.user
Message-ID <[email protected]>
On 04/27/2013 02:20 PM, Chris Jones wrote:
> On Sat, Apr 27, 2013 at 02:07:35PM EDT, Konstantin Svist wrote:
>
> [..]
>
>> Can that be made into a shortcut?
> As suggested in the addendum above you could bind the command sequence
> to a key.
>
> One way to do this would be to stick the two commands in a file:
>
> | $ cat $HOME/.scrbuff_screenrc
> | scrollback 0
> | scrollback 500
>
> And add something like this to your $HOME/.screenrc
>
> | bind 9 source $HOME/scrbuff_screenrc
>
> You would then be able to hit 'CTRL-A 9' to clear the contents of the
> scrollback buffer for the current screen window and reset it to a sane
> value (here 500 lines).
>
> I'm sure there are more elegant ways to do this, using a gnu/screen
> registers for instance, but I wouldn't know the exact syntax off the top
> of my head. 
>
> By 'elegant' I mean a solution that lets you stick everything in your
> .screenrc and avoid the clumsy extra file.
>
> CJ
>

perfect! :)
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.