* are there any patches which add ~ expansion to rc
@ 1997-09-17 15:56 Joseph Skinner
1997-09-17 21:56 ` Scott Schwartz
` (2 more replies)
0 siblings, 3 replies; 8+ messages in thread
From: Joseph Skinner @ 1997-09-17 15:56 UTC (permalink / raw)
To: rc
Hi
the title just about says it all.
This is one of the few things that I miss from bash and have noted that
this has been added to es.
What is the general view of this being part of rc.
Also where can I get the latest version of rc and it still being
actively developed.
Joe.
--
=======================================================================
in real life: Joseph Skinner |There's no such thing as a wizard
email: joe@earthlight.co.nz |who minds his own business
jskinner@es.co.nz | - Berengis the Black
http: www.earthlight.co.nz/users/joe| Court Mage to the Earls Caeline
========================================================================
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: are there any patches which add ~ expansion to rc
1997-09-17 15:56 are there any patches which add ~ expansion to rc Joseph Skinner
@ 1997-09-17 21:56 ` Scott Schwartz
1997-09-17 22:08 ` Mark K. Gardner
1997-09-18 10:14 ` Tim Goodwin
2 siblings, 0 replies; 8+ messages in thread
From: Scott Schwartz @ 1997-09-17 21:56 UTC (permalink / raw)
To: Joseph Skinner; +Cc: rc
Joseph Skinner <joe@earthlight.co.nz> writes:
| What is the general view of this being part of rc.
Wrong level of abstraction. Your os should provide a (virtual)
filesystem mounted on "/u" so you can say /u/username in every
context. Sun's automounter can almost do this right; amd can
probably do better.
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: are there any patches which add ~ expansion to rc
1997-09-17 15:56 are there any patches which add ~ expansion to rc Joseph Skinner
1997-09-17 21:56 ` Scott Schwartz
@ 1997-09-17 22:08 ` Mark K. Gardner
1997-09-18 10:14 ` Tim Goodwin
2 siblings, 0 replies; 8+ messages in thread
From: Mark K. Gardner @ 1997-09-17 22:08 UTC (permalink / raw)
To: joe; +Cc: rc
Joe,
A while ago I hacked rc to add ~ expansion. (It was a real kludge.)
However, after thinking about it more I decided that expansion really
belongs in readline/editline. So I modified readline v2.1 to support
it. I then had to make a relatively minor change to rc to initialize
readline properly and to perform expansion.
[Caveat: I decided not to use ~ because of its obvious conflict with
pattern matching in rc. Instead I used % which seems to be free. It
would have been better if the final expansion was done in readline,
but it appeared that readline would be too easy to break.]
The modification works fine. I have to remember to use ~ instead of %
in emacs though! The patch is too long to post and is of (perhaps)
limited interest so I will email it to you directly.
Mark
--
Mark K. Gardner (mkgardne@cs.uiuc.edu)
University of Illinois at Urbana-Champaign
Real-Time Systems Laboratory
--
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: are there any patches which add ~ expansion to rc
1997-09-17 15:56 are there any patches which add ~ expansion to rc Joseph Skinner
1997-09-17 21:56 ` Scott Schwartz
1997-09-17 22:08 ` Mark K. Gardner
@ 1997-09-18 10:14 ` Tim Goodwin
1997-09-18 23:26 ` Chris Siebenmann
2 siblings, 1 reply; 8+ messages in thread
From: Tim Goodwin @ 1997-09-18 10:14 UTC (permalink / raw)
To: Joseph Skinner; +Cc: rc
> What is the general view of this being part of rc.
I agree with Scott that this should be in the filesystem. If not, you
have to add it to every last application that uses filenames. (Here,
`/home/foo' works everywhere for all foo, although I'm not entirely
happy about the symlink farm that makes it happen...)
> Also where can I get the latest version of rc and it still being
> actively developed.
The latest full release is still 1.4, but you might like to try the
latest beta release 1.5b2. You can get it from these places.
ftp://ftp.sys.utoronto.ca/pub/rc/rc-1.5b2.tar.gz
ftp://ftp.pipex.net/people/tim/rc-1.5b2.tar.gz
Let me know if you don't have the one-line patch I posted to the list
the other day.
Tim.
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: are there any patches which add ~ expansion to rc
1997-09-18 10:14 ` Tim Goodwin
@ 1997-09-18 23:26 ` Chris Siebenmann
1997-09-19 17:21 ` Jeremy Fitzhardinge
0 siblings, 1 reply; 8+ messages in thread
From: Chris Siebenmann @ 1997-09-18 23:26 UTC (permalink / raw)
To: rc
Our local solution is a /u directory (automatically) populated with
symlinks that point to the appropriate places. We've been running it
for years without problems; I can mail people copies of either a sh
or a perl version[*] of the script that maintains /u if desired.
I've repeatedly found it very handy to have a short name for home
directories that works in every program and situation. And better
yet there's no need to clog up umpteen programs with code to do ~
expansion.
- cks
[*: yes, I know I was giving in to the evil empire, but I decided I
needed a decently fast program for the system with circa 10,000
passwd entries.]
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: are there any patches which add ~ expansion to rc
1997-09-18 23:26 ` Chris Siebenmann
@ 1997-09-19 17:21 ` Jeremy Fitzhardinge
0 siblings, 0 replies; 8+ messages in thread
From: Jeremy Fitzhardinge @ 1997-09-19 17:21 UTC (permalink / raw)
To: Chris Siebenmann; +Cc: rc
On Sep 18, 7:26pm, Chris Siebenmann wrote:
> Our local solution is a /u directory (automatically) populated with
> symlinks that point to the appropriate places. We've been running it
> for years without problems; I can mail people copies of either a sh
> or a perl version[*] of the script that maintains /u if desired.
While I agree that /u is an elegant approach to dealing with the ~user
problem, the most common use of ~ is when referring to one's own
home directory, which /u doesn't help with. I once implemented /u
as a user-space filesystem under Linux which generated its contents
on demand from /etc/passwd. It also had a /u/me which always referred
to the caller's home direcory, which is hard to do with a conventional
symlink /u.
The $H solution is OK for rc, but it has the same problems as ~, in that
not everything will understand it.
J
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: are there any patches which add ~ expansion to rc
@ 1997-09-19 7:51 Steve_Kilbane
0 siblings, 0 replies; 8+ messages in thread
From: Steve_Kilbane @ 1997-09-19 7:51 UTC (permalink / raw)
To: jeremy; +Cc: rc
> While I agree that /u is an elegant approach to dealing with the ~user
> problem, the most common use of ~ is when referring to one's own
> home directory, which /u doesn't help with.
True, but then, the problem lies in the ~ semantics, which aren't
great. Just as /u/foo can point to user foo's directory, /me (or /m)
can point to the current user's. Naturally, this needs special
handling in UNIX (as in /proc, /fd), and can be put in $home/lib/profile
in Plan 9.
What's really annoying is that this is one of the few things that
DOS can handle, and plain ol' UNIX can't.
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: are there any patches which add ~ expansion to rc
@ 1997-09-18 2:27 arnold
0 siblings, 0 replies; 8+ messages in thread
From: arnold @ 1997-09-18 2:27 UTC (permalink / raw)
To: rc; +Cc: joe
> the title just about says it all.
I think I did it years ago, it's pretty easy.
If you use GNU readline with rc, I (long ago) added ESC-& (I think)
to do ~ expansion (in vi mode). Try that and see if it still works.
(I use 9term and es).
---
Arnold Robbins Internet: arnold@gnu.ai.mit.edu
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~1997-09-19 21:53 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1997-09-17 15:56 are there any patches which add ~ expansion to rc Joseph Skinner
1997-09-17 21:56 ` Scott Schwartz
1997-09-17 22:08 ` Mark K. Gardner
1997-09-18 10:14 ` Tim Goodwin
1997-09-18 23:26 ` Chris Siebenmann
1997-09-19 17:21 ` Jeremy Fitzhardinge
1997-09-18 2:27 arnold
1997-09-19 7:51 Steve_Kilbane
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).