9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
From: "Russ Cox" <rsc@plan9.bell-labs.com>
To: 9fans@cse.psu.edu
Subject: Re: [9fans] Double Your input with cons
Date: Thu, 11 Jan 2001 13:48:13 -0500	[thread overview]
Message-ID: <20010111184823.952A5199E9@mail.cse.psu.edu> (raw)

I can't explain the doubling behavior.

  Also when I 1,2 cut and leave an empty line, it still executes
  what was on the line.  If I do an ls, cut the ls, and return,
  I get the listing anyway.  

This is happening because while rc in a rio window is 
reading from the terminal in line-at-a-time mode
(so you can edit the line before hitting enter),
con by default reads in raw character-at-a-time mode.
Once you type the ls, the other side has those characters,
and there's no way (short of typing backspace) to get 
them back.

This is analogous to having typed
	for (i in *)
and hit enter at a rio prompt.  You're still in the
middle of input, you can edit the current line all you
want, but the previous line, although still part of
the logical unit, has been digested by rc and editing
it will not change what it was to rc.

It sounds like what you want is con -C, which sends
input a line at a time and turns on local echo.  (You'll
have to "stty -echo" on the Unix side or you'll go nuts.)

Russ


             reply	other threads:[~2001-01-11 18:48 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-01-11 18:48 Russ Cox [this message]
  -- strict thread matches above, loose matches on Subject: below --
2001-01-12 18:02 Mark C. Otto
2001-01-11 20:06 rog
2001-01-11 18:23 Mark Otto

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20010111184823.952A5199E9@mail.cse.psu.edu \
    --to=rsc@plan9.bell-labs.com \
    --cc=9fans@cse.psu.edu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).