Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.user > #227186

Re: spurious CR/LF on tty (was: how to remove GUI)

From David <bouncingcats@gmail.com>
Newsgroups linux.debian.user
Subject Re: spurious CR/LF on tty (was: how to remove GUI)
Date 2020-09-21 04:20 +0200
Message-ID <ARjAS-7dH-5@gated-at.bofh.it> (permalink)
References (5 earlier) <ANTtg-5mO-3@gated-at.bofh.it> <ANWKt-7rh-3@gated-at.bofh.it> <AOccy-8hi-11@gated-at.bofh.it> <AOMg1-4YC-3@gated-at.bofh.it> <AOVjj-1Li-3@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Mon, 14 Sep 2020 at 21:56, Greg Wooledge <wooledg@eeg.ccf.org> wrote:
> On Sun, Sep 13, 2020 at 09:14:54PM -0500, David Wright wrote:
> > On Sat 12 Sep 2020 at 21:45:34 (+1000), David wrote:

> > > And regarding "just hit the enter key ... and all is fine", this
> > > behaviour does not just occur at a login prompt. If you login quickly
> > > as root to a minimal install as I often do, this behaviour occurs
> > > during root console use, and if one is half-way through typing a
> > > command which suddenly disappears from view, pressing enter could be a
> > > recipe for disaster.

> > > (eg dd before I have added the count= parameter).

> > > So my habit when it occurs has become to: ctrl-u, enter, ctrl-y.

> It's the same general kind of problem that you can face during terminal
> usage in many situations.  Something unexpectedly scribbles on your
> terminal while you're typing, whether it's modem line noise, or the
> kernel warning all users of an imminent reboot, or a background job
> you forgot you had running, or whatever.

> There are many ways to work around it.  My preferred way is to clear
> the screen with Ctrl-L (ESC Ctrl-L for me, because I use bash in vi
> mode).  That will redraw the shell prompt and the partially typed
> command after clearing the screen, and allow you to continue typing.

Thank you very much for that advice. I was not aware that bash
"clear-screen" has the feature of repainting the partially typed
command. This exactly addresses what was causing my concern, so I am
less troubled by this now.

For curiosity, I had a look at 'man bash' (on buster), it hints about
this feature in a way that might seem clear to someone who already knew
it, but does not communicate it clearly to me (ie someone with no
prior knowledge of it).

"clear-screen: Clear the screen leaving the current line at the top of
the screen."

The word "leaving" is what misdirects me.

Without knowing the actual behaviour, that sentence suggests to me
that the *current* (ie broken or invisible) line would be *left*
(ie unchanged) at the top. The sentence would better describe to me the
useful behaviour if it read something like:

"clear-screen: Clear the screen, redrawing the current line at the top
of the screen."

or

"clear-screen: Clear the screen, placing the current line at the top
of the screen, and redrawing any readline buffer contents."

Back to linux.debian.user | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

how to remove GUI "Michael Morgan" <michaelmorgan937@gmail.com> - 2020-09-11 06:40 +0200
  Re: how to remove GUI Andrei POPESCU <andreimpopescu@gmail.com> - 2020-09-11 08:40 +0200
    Re: how to remove GUI Andrei POPESCU <andreimpopescu@gmail.com> - 2020-09-11 08:40 +0200
  Re: how to remove GUI Joe <joe@jretrading.com> - 2020-09-11 10:10 +0200
  Re: how to remove GUI Henning Follmann <hfollmann@itcfollmann.com> - 2020-09-11 14:00 +0200
    Re: how to remove GUI Kenneth Parker <sea7kenp@gmail.com> - 2020-09-11 15:10 +0200
      Re: how to remove GUI Greg Wooledge <wooledg@eeg.ccf.org> - 2020-09-11 16:40 +0200
        Re: how to remove GUI David Wright <deblis@lionunicorn.co.uk> - 2020-09-11 17:40 +0200
          Re: how to remove GUI Greg Wooledge <wooledg@eeg.ccf.org> - 2020-09-11 17:50 +0200
            Re: spurious CR/LF on tty (was: how to remove GUI) Felix Miata <mrmazda@earthlink.net> - 2020-09-11 21:20 +0200
              Re: spurious CR/LF on tty (was: how to remove GUI) David Wright <deblis@lionunicorn.co.uk> - 2020-09-12 04:10 +0200
              Re: spurious CR/LF on tty (was: how to remove GUI) David <bouncingcats@gmail.com> - 2020-09-12 13:50 +0200
                Re: spurious CR/LF on tty (was: how to remove GUI) David Wright <deblis@lionunicorn.co.uk> - 2020-09-14 04:20 +0200
                Re: spurious CR/LF on tty (was: how to remove GUI) Greg Wooledge <wooledg@eeg.ccf.org> - 2020-09-14 14:00 +0200
                Re: spurious CR/LF on tty (was: how to remove GUI) David <bouncingcats@gmail.com> - 2020-09-21 04:20 +0200
                Re: spurious CR/LF on tty (was: how to remove GUI) David Wright <deblis@lionunicorn.co.uk> - 2020-09-21 16:40 +0200
          Re: how to remove GUI Andrei POPESCU <andreimpopescu@gmail.com> - 2020-09-12 11:50 +0200
  Re: how to remove GUI Greg Wooledge <wooledg@eeg.ccf.org> - 2020-09-11 14:00 +0200
    Re: how to remove GUI rhkramer@gmail.com - 2020-09-11 14:40 +0200

csiph-web