9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
From: Richard Uhtenwoldt <ru@ohio.river.org>
To: 9fans@cse.psu.edu
Subject: [9fans] command history
Date: Fri, 14 Jul 2000 14:03:17 -0700	[thread overview]
Message-ID: <200007142103.OAA06763@ohio.river.org> (raw)
In-Reply-To: <200007141416.JAA16884@sch1.NCTR.FDA.GOV>

Stephen C. Harris writes:
>Anthony Sorace <anothy@eden.rutgers.edu> wrote:
>> //is it possible to use history and command completion with rc?
>>  
>> no. rc has neither of these functions. history is the job of the 
>> windowing system - simply snarf your previous commands, edit in 
>> place, send them down... it's much better than the history built 
>> into most shells
>
>Except if there's a lot of output, or you want to go back more than one
>command, it's sometimes hard to find your previous command in the first 
>place.

I'm a Plan 9 newbie, but in case no one else has any other suggestions
I thought I'd mention ILE, which I learned of on the rc mailing list.

ile lets you scroll line by line up and down the commandline history and
also to search backwards through the history.  on a user-interface note,
the search command is modeless; in contrast, bash's search command (^s)
is modal.

ile has filename completion (it looks at Linux /proc to determine
the shell's cwd), but of course we know that the Plan 9 way is not
filename completion but rather, e.g., to get the name of the file in an
Acme window where you can click on it with button 3 of the mouse.

it also has a bunch of affordances --delete_word and such-- for editing
a command line --a task that in the Plan 9 style is done with a mouse
and Rio.

on Linux, ile uses a pty.  on Plan 9, ILE could modify the /dev/cons
that rc sees.  i.e., instead of rio invoking "rc", rio could invoke
"ile;rc" where the only effect of the ile command is to bind /dev/cons
to a fileserver which stores the commandline history and interprets the
history-editing commands.  that way, no modification to rc or rio would
be needed: ile would "sit between" rio and rc.

from the readme of "ile-linux.tgz":

README FOR LINUX VERSION OF ile -- INPUT LINE EDITOR

This is a port/enhancement of Rob Pendelton's ILE pty front end to
the Linux OS.  I myself mostly use it for 'rc' -- the unix port of the
USL plan 9 shell -- because it has no builtin line editing, and for
ash the excellent enhanced /bin/sh clone which also has no line editing.
I used to use it for 'ftp', but then I got ncftp.  I've found it to work
more reliably than 'atty' another popular front end, though its source code
is probably less modular.  It is nearly seven years old (much older than Linux
itself in fact ;-) but it works with Linux' pty's.  I have a lot of ideas
for enhancements, but I don't know if I'll get around to them.  I call this
the Linux version because it uses /proc/*/cwd for filename completions which
is *much* cleaner than any other pty-front end has at present.  (They mostly
use generous assumptions that the underlying process is a shell and prints out
prompts and can send codes in the prompts saying what the directory is, etc.)

                                                Charles Blake, 07/28/1994




  reply	other threads:[~2000-07-14 21:03 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2000-07-14 14:16 Stephen C. Harris
2000-07-14 21:03 ` Richard Uhtenwoldt [this message]
2000-07-14 21:25   ` Richard Uhtenwoldt
2000-07-14 19:44 Russ Cox
2000-07-14 21:37 Russ Cox
2000-07-14 23:24 ` Richard

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=200007142103.OAA06763@ohio.river.org \
    --to=ru@ohio.river.org \
    --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).