DEV Community

Brisbane Web Developer
Brisbane Web Developer

Posted on

How to clear scrollback on screen

Sumarry

I wanted to make my Konsole to let me clear scrollback while I am using screen so I googled how to do that.

Answer

~/.screenrc
======
defscrollback 50000

# Press "Ctrl + a", "/" and then "Enter" to clear scrollback
# - Konsole disables the functionality if it is on subshell (= screen)
bind / eval "clear" "scrollback 0" "scrollback 50000"
Enter fullscreen mode Exit fullscreen mode

References

Top comments (0)