Konsole/Terminal Clear screen when end of screen .. [Solved]

Discussions Regarding Software

Moderator: Moderators

User avatar
sabayonino
Sagely Hen
Posts: 3253
Joined: Sun Sep 21, 2008 1:12
Location: Italy
Contact:

Re: Konsole/Terminal Clear screen when end of screen .. [Sol

Post by sabayonino » Mon Mar 12, 2018 22:47

again ... please put the bash code using the "code" button !!
[Che Cos'è Il Calcolo Distribuito (BOINC)

BOINC ready ! Sabayon+BOINC = BILD ,my Sabayon spin :cyclops: - Ready to crunch for the Science everywhere :)

flexoron
Young Hen
Posts: 37
Joined: Tue Sep 26, 2017 23:17

Re: Konsole/Terminal Clear screen when end of screen .. [Sol

Post by flexoron » Tue Mar 13, 2018 21:34

One last hint!
You can feed the pager with all text files in a directory. For example:

Code: Select all

./pagertest -cm='cat *.txt'
Stop

Code: Select all

Ctrl-Z
[1]+  Stopped  ./pagertest -cm='cat *.txt'
kill %1
[1]+  Terminated
And you can apply the Unix philosophy chaining tools together:

Code: Select all

./pagertest -cm='for i in {1..99} ;do echo $i; done | xargs -n3 | sed "s/ /+/g" | bc'
The command calculates the sum of 3 numbers.
6 (1+2+3)
15 (4+5+6)
24 (7+8+9)
:
294 (97+98+99)

Sometimes at first glance not only scripts look complicated but commands, too :)

User avatar
linuxfluesterer
Old Dear Hen
Posts: 870
Joined: Thu Sep 20, 2012 19:47
Location: Germany

Re: Konsole/Terminal Clear screen when end of screen .. [Sol

Post by linuxfluesterer » Wed Mar 14, 2018 16:07

Thank you again!
I like your post, and I've learned something new also. (In between I understand, what you mean with background process and how to stop it ;) ).

-Linuxfluesterer (I love KDE...)
Take away Facebook from me and let there be real people again...

Post Reply