* Re: [9fans] blanks in file names
@ 2002-07-08 20:22 rob pike, esq.
2002-07-08 21:21 ` Dave
0 siblings, 1 reply; 103+ messages in thread
From: rob pike, esq. @ 2002-07-08 20:22 UTC (permalink / raw)
To: 9fans
> changing open(2), execve(2), etc. is
> a requirement if we want a fundamental solution to the problem.
Fundamental solutions should be applied only to fundamental problems.
This is not a fundamental problem; far from it. The means should be
proportionate to the ends.
> > Don't you think that changing open, considering '/' in names, and
> > similar stuff is just too much?
Yes, it is, because to do so contradicts too many conventions that are
integral to the system.
-rob
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
2002-07-08 20:22 [9fans] blanks in file names rob pike, esq.
@ 2002-07-08 21:21 ` Dave
2002-07-08 23:27 ` Dan Cross
0 siblings, 1 reply; 103+ messages in thread
From: Dave @ 2002-07-08 21:21 UTC (permalink / raw)
To: 9fans
Okay, I see where you're going with this. I fear I'm very badly
outnumbered here, and since I'm not about to implement the changes I
suggest, nobody else is likely to. I guess we'll just have to keep
blanks out of our filenames. . .
- Dave
BTW - If we change the system in a fundamental way once and for all,
we'll have a system (and a new set of conventions) that won't have to
be changed for another 50 years, with any luck. Somebody's going to
want to encode full pathnames within nodes at some point in the future,
and our decision to disallow that will force people to invent roundabout
ways of doing so.
rob pike, esq. wrote:
>
> > changing open(2), execve(2), etc. is
> > a requirement if we want a fundamental solution to the problem.
>
> Fundamental solutions should be applied only to fundamental problems.
> This is not a fundamental problem; far from it. The means should be
> proportionate to the ends.
>
> > > Don't you think that changing open, considering '/' in names, and
> > > similar stuff is just too much?
>
> Yes, it is, because to do so contradicts too many conventions that are
> integral to the system.
>
> -rob
>
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
2002-07-08 21:21 ` Dave
@ 2002-07-08 23:27 ` Dan Cross
2002-07-08 23:30 ` Dan Cross
0 siblings, 1 reply; 103+ messages in thread
From: Dan Cross @ 2002-07-08 23:27 UTC (permalink / raw)
To: 9fans
> BTW - If we change the system in a fundamental way once and for all,
> we'll have a system (and a new set of conventions) that won't have to
> be changed for another 50 years, with any luck. Somebody's going to
> want to encode full pathnames within nodes at some point in the future,
> and our decision to disallow that will force people to invent roundabout
> ways of doing so.
IBM did that with their match-mode mainframe operating system. Low and
behold, it didn't change for 50 years.
- Dan C.
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
@ 2002-07-15 4:03 Geoff Collyer
2002-07-15 14:53 ` Jack Johnson
2002-07-21 19:47 ` Dave
0 siblings, 2 replies; 103+ messages in thread
From: Geoff Collyer @ 2002-07-15 4:03 UTC (permalink / raw)
To: 9fans
My apologies for dragging this out, but I think this gets to the heart
of the matter.
The cost of strlen doesn't matter, it really doesn't matter. I can't
recall seeing a real-life program where the cost of strlen was more
than trivia.
A quick comparison on Plan 9 shows that strlen runs at 19 times the
speed of DES, using the same 64-byte string as input each time, which
is almost certainly longer than the average string. DES is really
slow, by design; it's not just a question of a few more memory
accesses; it's just hard to do the bit-swizzling quickly in software
(though it can be done relatively quickly in hardware).
One of the big achievements of Unix was to get people to stop worrying
about the microseconds and look at the slightly larger picture of what
could be done if your first concern were not microseconds, and that
was a quarter-century ago! With processor cycles being so cheap and
available now, it's generally not worth worrying about expenses until
they cause a real (measurable, reproducible) problem. Proposals based
on supposedly greater efficiency for a new open(2) interface are not
worth considering, particularly when open's efficiency isn't currently
a problem, and the new interface is ugly, incompatible with the
existing clean and simple one, and purports to solve non-problems like
allowing NUL and slash in file name components.
One downside of APE is that it's made some people think of Plan 9 as
Just Another Goddamned Unix Implementation. If you're not interested
in exploring what's new in Plan 9, and are offended that realloc isn't
provably optimal or that GNU configure doesn't just run out the box,
why are you using Plan 9? FreeBSD, OpenBSD, NetBSD and Linux are all
available at no monetary cost.
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
2002-07-15 4:03 Geoff Collyer
@ 2002-07-15 14:53 ` Jack Johnson
2002-07-21 19:52 ` Dave
2002-07-21 19:47 ` Dave
1 sibling, 1 reply; 103+ messages in thread
From: Jack Johnson @ 2002-07-15 14:53 UTC (permalink / raw)
To: 9fans
Geoff Collyer wrote:
> One downside of APE is that it's made some people think of Plan 9 as
> Just Another Goddamned Unix Implementation.
Is this what Dave meant when he wrote:
> /me shudders at the thought that GUIs might someday take over the
> world :-(
?
For the record, I think Plan 9 is a textual GUI. Though you could
probably swing it with a bare rc shell, unless you can run it on a
braille term (or hear it through your speakers) it's probably safest to
call it a GUI.
At this point, I guess I'm thankful that there are no Olfactory User
Interfaces (though paradoxically I've seen a few that stank).
I did read somewhere that there's a braille term that can draw out
window regions. A variation of acme on something like that could be
interesting. Mouse actions would take some serious rethought, though.
-Jack
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
2002-07-15 14:53 ` Jack Johnson
@ 2002-07-21 19:52 ` Dave
0 siblings, 0 replies; 103+ messages in thread
From: Dave @ 2002-07-21 19:52 UTC (permalink / raw)
To: 9fans
I happen to dislike much about rio, but that's not a fundamental part
of the OS; it's simply a shell (and a very good one, too, which is why
you're not likely to see me rushing to replace it). FWIW, though, I can
easily imagine a vi-like or emacs-like environment with a framebuffer
back-end doing the job just fine, without rodents, and without losing
any functionality.
- Dave
Jack Johnson wrote:
>
> Geoff Collyer wrote:
> > One downside of APE is that it's made some people think of Plan 9 as
> > Just Another Goddamned Unix Implementation.
>
> Is this what Dave meant when he wrote:
> > /me shudders at the thought that GUIs might someday take over the
> > world :-(
>
> ?
>
> For the record, I think Plan 9 is a textual GUI. Though you could
> probably swing it with a bare rc shell, unless you can run it on a
> braille term (or hear it through your speakers) it's probably safest to
> call it a GUI.
>
> At this point, I guess I'm thankful that there are no Olfactory User
> Interfaces (though paradoxically I've seen a few that stank).
>
> I did read somewhere that there's a braille term that can draw out
> window regions. A variation of acme on something like that could be
> interesting. Mouse actions would take some serious rethought, though.
>
> -Jack
>
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
2002-07-15 4:03 Geoff Collyer
2002-07-15 14:53 ` Jack Johnson
@ 2002-07-21 19:47 ` Dave
1 sibling, 0 replies; 103+ messages in thread
From: Dave @ 2002-07-21 19:47 UTC (permalink / raw)
To: 9fans
I just noticed that there were a few more messages in this thread that
got lost in my email (and I can't really blame elm this time, either) :-(
I know we'd all like to kill this thread, but I can't look at this post
without replying; it's just too misguided to ignore.
The reason I want a new open is _not_ that the current open isn't
efficient enough for my tastes. The reason I want a new open is that the
current one was lifted straight out of the old UNIX design, and miserably
fails to accomodate the modular approach that UNIX no longer provides,
but Plan 9 has found some brilliant ways of recreating (which is why I
got my original Plan9 installation in the first place). The fact that
the new open happens to be more efficient than the old one for many
applications is merely a neat side effect, one that I only brought up
when I was accused of making open _less_ efficient (and I didn't see you
pipe up then to complain that cost doesn't matter). In UNIX, paths never
became real objects in the sense that Plan 9 has promoted them to, because
UNIX has very primitive filesystem serving. In Plan 9, it becomes a lot
more interesting to have commands simply create temporary filesystems
and populate them with the results (e.g., ls creating a directory with
each file being one of the entries requested, and the contents of each
of those files being information about the entry). UNIX tried to make
everything a file, but it got bogged down with plain-text IO. Plan 9
aligned itself squarely with the file philosophy, and I see no reason
to stop short when filenames are concerned.
- Dave
BTW - I don't know if it's worth noting that while strlen (sequential
memory accesses) is an order of magnitude faster than DES (repeated
computations + sequential memory accesses), simply getting the length
from a structure (direct memory access) is an order of magnitude faster
than strlen.
Geoff Collyer wrote:
>
> My apologies for dragging this out, but I think this gets to the heart
> of the matter.
>
> The cost of strlen doesn't matter, it really doesn't matter. I can't
> recall seeing a real-life program where the cost of strlen was more
> than trivia.
>
> A quick comparison on Plan 9 shows that strlen runs at 19 times the
> speed of DES, using the same 64-byte string as input each time, which
> is almost certainly longer than the average string. DES is really
> slow, by design; it's not just a question of a few more memory
> accesses; it's just hard to do the bit-swizzling quickly in software
> (though it can be done relatively quickly in hardware).
>
> One of the big achievements of Unix was to get people to stop worrying
> about the microseconds and look at the slightly larger picture of what
> could be done if your first concern were not microseconds, and that
> was a quarter-century ago! With processor cycles being so cheap and
> available now, it's generally not worth worrying about expenses until
> they cause a real (measurable, reproducible) problem. Proposals based
> on supposedly greater efficiency for a new open(2) interface are not
> worth considering, particularly when open's efficiency isn't currently
> a problem, and the new interface is ugly, incompatible with the
> existing clean and simple one, and purports to solve non-problems like
> allowing NUL and slash in file name components.
>
>
> One downside of APE is that it's made some people think of Plan 9 as
> Just Another Goddamned Unix Implementation. If you're not interested
> in exploring what's new in Plan 9, and are offended that realloc isn't
> provably optimal or that GNU configure doesn't just run out the box,
> why are you using Plan 9? FreeBSD, OpenBSD, NetBSD and Linux are all
> available at no monetary cost.
>
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
@ 2002-07-14 18:28 rob pike, esq.
0 siblings, 0 replies; 103+ messages in thread
From: rob pike, esq. @ 2002-07-14 18:28 UTC (permalink / raw)
To: 9fans
> > strlen() is an expensive operation.
>
> No, it's not terribly expensive.
The strlen() of this thread is certainly an expensive operation.
-rob
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
@ 2002-07-11 23:56 okamoto
0 siblings, 0 replies; 103+ messages in thread
From: okamoto @ 2002-07-11 23:56 UTC (permalink / raw)
To: 9fans
>The idea was born from the discussion between Dave and I.
>Dave proposed '\' escape.
No, both are completely misunderstanding the point which Rob pointed.
You can read once more his and nemo's remarks before.
Kenji
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
@ 2002-07-11 8:39 Geoff Collyer
2002-07-14 18:13 ` Dave
0 siblings, 1 reply; 103+ messages in thread
From: Geoff Collyer @ 2002-07-11 8:39 UTC (permalink / raw)
To: 9fans
dave@dave.tj,
Have you actually used Plan 9 or even read its manual? I ask because
you've made a succession of odd statements:
> strlen() is an expensive operation.
No, it's not terribly expensive. Even if it were, most strings are
short, so it's not much of an issue. DES encryption is expensive.
> realloc() sucks in a multithreaded environment.
You don't define ``sucks'', but the whole malloc family use internal
locks on Plan 9 so that they *do* work well (or at least don't corrupt
memory) in multiprocess or multithread programs.
> Also, I'd like to mention again that I'm not asking the kernel to
> allocate memory.
The kernel already allocates memory, including string memory. What's
the big deal?
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
2002-07-11 8:39 Geoff Collyer
@ 2002-07-14 18:13 ` Dave
0 siblings, 0 replies; 103+ messages in thread
From: Dave @ 2002-07-14 18:13 UTC (permalink / raw)
To: 9fans
Reply inline:
- Dave
Geoff Collyer wrote:
>
> dave@dave.tj,
>
> Have you actually used Plan 9 or even read its manual? I ask because
> you've made a succession of odd statements:
Yup, I had Release 3 on an old system (which I tried to upgrade to Release
4, to no avail), although I must admit that it wasn't my preferred
platform. Everything from the directory structure to the process of
trying to compile standard UNIX-compatible software was extremely awkward.
I was hoping to give Release 4 a try, but until I can get the Millenium
(or the Blade 3D, my only other card) to work with Release 4, I'm out
of luck. As for the manual, no way ... I never read the manual until
I run into trouble ;-P
>
> > strlen() is an expensive operation.
>
> No, it's not terribly expensive. Even if it were, most strings are
> short, so it's not much of an issue. DES encryption is expensive.
It must examine every byte in the array, and that's an expensive
operation. DES must examine every byte multiple times, so it's a very
expensive operation. The structure method doesn't require access to
every byte in the array, since the length is counted.
>
> > realloc() sucks in a multithreaded environment.
>
> You don't define ``sucks'', but the whole malloc family use internal
> locks on Plan 9 so that they *do* work well (or at least don't corrupt
> memory) in multiprocess or multithread programs.
Yup, I should've defined "sucks" - here goes:
suck - v. being rediculously inefficient, due to the need to move the
realloc(3)ed chunk almost constantly, because realloc(3) isn't smart
enough to know that another realloc(3) in another thread is also growing
a block, and realloc(3) hates stepping on other realloc(3)s' toes
(BTW - realloc(3) can also suck in a single-threaded environment (two
arrays that are growing in the same thread), but it's more common
for it to be used in a way that causes it to suck in multi-threaded
environments.)
>
> > Also, I'd like to mention again that I'm not asking the kernel to
> > allocate memory.
>
> The kernel already allocates memory, including string memory. What's
> the big deal?
AFAIK, the kernel does _not_ allocate userland memory with anything
but the brk(2) call - which is only called by malloc(3), realloc(3),
and operator new(). Please correct me if I'm wrong.
>
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
@ 2002-07-11 5:50 okamoto
0 siblings, 0 replies; 103+ messages in thread
From: okamoto @ 2002-07-11 5:50 UTC (permalink / raw)
To: 9fans
>Eh, I tire of the discussion
Yes, indeed.
We can refer to a statement from Rob times before.
Kenji
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
@ 2002-07-11 1:41 anothy
[not found] ` <"anothy@cosym.net"@Jul>
0 siblings, 1 reply; 103+ messages in thread
From: anothy @ 2002-07-11 1:41 UTC (permalink / raw)
To: 9fans
on the "linked lists for paths instead of strings with /" topic:
while i can see how this could be interesting to persue, from a
systems architecture research point of view, i'm unclear on how
exactly this helps us solve any of the problems people are
talking about. maybe i'm just missing something; if so, please
clue me in. but here's what i don't see:
first, it seems your suggestion is primarialy aimed at allowing
"/" in file names (perhaps some argument about generality or
interoperation with DOS-derived systems and "\" could be made,
as well). okay, i can see the theoretical benefit there (but it
strikes me as a much more dubious gain than spaces in file
names). but what would this system _look_ like, from a user's
point of view? what would the output of `pwd' be? a list of
strings? but how can i store a representation of that? wouldn't
that involve lots of interaction with the shell, or whatever
else was doing the interpretation (like $path does, although
that's used is very few places, and is very function-specific,
so isn't really much of an issue)?
second, i'm just not seeing at all how this helps us address
spaces in file names (and maybe it wasn't meant to; this
thread has wandered a bit). the dificult part of the problem
(perhaps the entirety of the problem) seems to lie in getting
the various tools that need to communicate to understand the
edges of file names: things like "grep `{ls} foo". i fail to
see how any of the kernel changes (or library additions) you
propose even talk to this realm of problem.
third: want newline too?
on another embedded thread, you wrote:
// You can do a lot of things if you're prepared to get
// involved in the functions that your OS should be doing
// automatically. Try running an FTP mirror to a busy site
// that way, though, and you'll quickly discover...
that you've completely missed what dan was saying? he (and
Nemo before him) was talking about the ability of Plan 9's
dump to back out changes to kernel, library, and utilitys
uniformly. i don't have a clue what FTP or HTTP mirrors or
"things your OS should do automatically" have to do with
any of this. are we just having unrelated conversations at
each other?
ア
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
@ 2002-07-10 18:27 David Gordon Hogan
2002-07-10 20:56 ` arisawa
0 siblings, 1 reply; 103+ messages in thread
From: David Gordon Hogan @ 2002-07-10 18:27 UTC (permalink / raw)
To: 9fans
Isn't this thread dead yet?
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
@ 2002-07-10 8:00 Fco.J.Ballesteros
0 siblings, 0 replies; 103+ messages in thread
From: Fco.J.Ballesteros @ 2002-07-10 8:00 UTC (permalink / raw)
To: 9fans
[-- Attachment #1: Type: text/plain, Size: 277 bytes --]
Really, I make changes now and then; many times after
trying the resulting binaries I change my mind and
use yesterday + cp to restore the source back to its
previous state. Some other times I bind temporary directories
on top of the sources and make the changes there.
[-- Attachment #2: Type: message/rfc822, Size: 2260 bytes --]
From: Dave <dave@dave.tj>
To: 9fans@cse.psu.edu
Subject: Re: [9fans] blanks in file names
Date: Tue, 09 Jul 2002 11:23:25 -0400 (EDT)
Message-ID: <200207091523.g69FNP431828@dave2.dave.tj>
You're not going to do that every time you make a change to the
filesystem. Besides, that won't undo all the "changes" to all the
new programs that lack complexity because they don't have to reinvent
the wheel.
- Dave
Fco.J.Ballesteros wrote:
>
> >> But above all, I will undo the changes made in this respect to my
> >> local system if you guys or the system designers choose a different way.
> ...
> > Undoing kernel-level changes won't be easy, especially when people start
>
> 9fs dump
> cp blah blah
>
> Sorry, couldn't resist. I just love this system :-)
>
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
@ 2002-07-09 7:54 Fco.J.Ballesteros
0 siblings, 0 replies; 103+ messages in thread
From: Fco.J.Ballesteros @ 2002-07-09 7:54 UTC (permalink / raw)
To: 9fans
>> But above all, I will undo the changes made in this respect to my
>> local system if you guys or the system designers choose a different way.
...
> Undoing kernel-level changes won't be easy, especially when people start
9fs dump
cp blah blah
Sorry, couldn't resist. I just love this system :-)
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
@ 2002-07-09 1:08 okamoto
0 siblings, 0 replies; 103+ messages in thread
From: okamoto @ 2002-07-09 1:08 UTC (permalink / raw)
To: 9fans
>if you are writing in english, not necessarily. yes if you are writing in
>japanese. in that case, it should have seventeen (five/seven/five) *onji*
>which is not a syllable, but a sound symbol.
Aa! Now, I understood the difference between 俳句 and Haiku.
I'll show you a 俳句example, which is one of the most famous one
written for this season by 芭蕉(Bashou) posted before.
古池や蛙とびこむ水の音
Abobe is written using Hiragana and Kanji, which is Japanese writing
style heritaged from Heian-Ara invented by Japanese women..., anyway
it should be read as
ふるいけや かわず とびこむ みずのおと
Now, you counts 5+7+5 hiraganas, which are the reading showtest units
(syllable?) in Japanese. Here, I intentianlly put 'blank' between 5+7+5,
but it not used formally.
Another thing, in 俳句 we need some key word which implies a season
when the author want to express. In the above example, it's 蛙(frog).
Frogs apear to us from early summer. So, I felt that an English version
of Haiku which someone showed here is not 俳句, but 川柳(senryu).
Sorry making noise.
Kenji -- Enjoying UTF-8 capability of Plan 9
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
@ 2002-07-08 23:19 David Gordon Hogan
2002-07-08 23:30 ` Dave
0 siblings, 1 reply; 103+ messages in thread
From: David Gordon Hogan @ 2002-07-08 23:19 UTC (permalink / raw)
To: 9fans
>> I thought the making of saints wasn't exactly in the kernel's job
>> description.
>
> Naw, making saints is "canonization". Making artillery is a perfectly
> good kernel task.
Such kernels may, however, be subject to export restrictions...
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
@ 2002-07-08 12:18 forsyth
[not found] ` <"forsyth@caldo.demon.co.uk"@Jul>
0 siblings, 1 reply; 103+ messages in thread
From: forsyth @ 2002-07-08 12:18 UTC (permalink / raw)
To: 9fans
>>Finally, it gives us the capability of getting away from even the most
>>elementary requirements in a filesystem (like inodes) at some point in
>>the future without extensive code changes. Basically, it's all about
Plan 9 hasn't really got assumptions about inodes. 9P doesn't use them.
(makes it tricky to do NFS, as it happens, though that's not Plan 9's fault
this time.)
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
@ 2002-07-08 8:59 Fco.J.Ballesteros
[not found] ` <Fco.J.Ballesteros@Jul>
0 siblings, 1 reply; 103+ messages in thread
From: Fco.J.Ballesteros @ 2002-07-08 8:59 UTC (permalink / raw)
To: 9fans
I think we've lost focus. I'm scared.
The whole point was to handle characters which are allowed but may
cause problems like ' ' and ''''. And AFAIK, the problem was that we
get them from outside systems, and that people may be so used to them
that they may even start to use them on native Plan 9 files.
Don't you think that changing open, considering '/' in names, and
similar stuff is just too much? I'm scared. That may be interesting,
but it would lead to a very different system.
Moreover, do you think that the system designers would ever consider
'/' as a legitimate character within file names? Although I don't
know, I'd bet they'll never do that (at least I have to say I would
never do it, sorry).
I think I'm just going to try option bⁱ myself and then send a diff
in case it works out.
But above all, I will undo the changes made in this respect to my
local system if you guys or the system designers choose a different way.
It's a very nice system and I wouldn't like to get N different ones
nor to break it.
--
ⁱ Option b was: remove quoting from ls et al, add it to those that
print commands, and fix those that don't cosider ' ' in file names.
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
@ 2002-07-08 0:38 Scott Schwartz
0 siblings, 0 replies; 103+ messages in thread
From: Scott Schwartz @ 2002-07-08 0:38 UTC (permalink / raw)
To: 9fans
| If '/' is prohibitted as an element of file name and directory name,
| then no change to open is required.
|
| Let's assume we accept '/' as an element of names,
| then how do you express path in rc?
cd (stl list/vector foo)
I think this discussion is verging on reinventing lisp, where you have a
well specified format for textually representing data, standard primatives
for reading and writing it, and a set of datatypes to store it in.
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
@ 2002-07-07 5:59 Geoff Collyer
0 siblings, 0 replies; 103+ messages in thread
From: Geoff Collyer @ 2002-07-07 5:59 UTC (permalink / raw)
To: 9fans
I had thought that one of my sicker ideas was too ridiculous to
suggest, but perhaps not, given the precedent:
A pair of kernel devices (or a single device with an encode or decode
indicator) to translate hURL-encoded file names into plan 9 file
names, and vice versa. After translation, they are passed to namec.
This lets you use all the glorious botches that have been invented for
hURL (or is it URI?) encoding.
#:dfile://localhost/my%20file
and
#:dmy%20file
would map to "my file". In the presence of a file server that
understands the encoded form, one could do the reverse mapping:
"#:emy file" should probably map to
my%20file
A further benefit of using the encoded form of names in files is that
programs can then guess fairly reliably which are file names: a field
starting with "file://localhost/" is likely to be a file name.
I'm not seriously suggesting using awful web syntax, but perhaps the
general idea suggests a way forward.
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
@ 2002-07-05 19:21 David Gordon Hogan
2002-07-05 19:52 ` Jim Choate
2002-07-05 20:10 ` Mark Bitting
0 siblings, 2 replies; 103+ messages in thread
From: David Gordon Hogan @ 2002-07-05 19:21 UTC (permalink / raw)
To: 9fans
>>>> Change space! Change the file delimiter!
>>>> The shell will never recover. The system will break.
>>>> I will mourn.
>>>
>>> Isn't a haiku supposed to have 17 syllables?
>>
>> Some would dispute the imposition of such an absolute rule.
>
> Is that why your message has only 16 syllables?
Word.
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
2002-07-05 19:21 David Gordon Hogan
@ 2002-07-05 19:52 ` Jim Choate
2002-07-05 20:10 ` Mark Bitting
1 sibling, 0 replies; 103+ messages in thread
From: Jim Choate @ 2002-07-05 19:52 UTC (permalink / raw)
To: 9fans
On Fri, 5 Jul 2002, David Gordon Hogan wrote:
> >>>> Change space! Change the file delimiter!
> >>>> The shell will never recover. The system will break.
> >>>> I will mourn.
> >>>
> >>> Isn't a haiku supposed to have 17 syllables?
> >>
> >> Some would dispute the imposition of such an absolute rule.
> >
> > Is that why your message has only 16 syllables?
>
> Word.
Actually only one style of Hiaku uses 17 'syllables' in Japanese. Not the
same thing as English 'syllables'. For an excellent discussion on this
point, and how to compensate for it...
The Haiku Handbook: How to write, share, and teach Haiku
W.J. Higginson, P. Harter
ISBN 4-7700-1430-9
$13 US
Enjoy!
--
____________________________________________________________________
When I die, I would like to be born again as me.
Hugh Hefner
ravage@ssz.com www.ssz.com
jchoate@open-forge.org www.open-forge.org
--------------------------------------------------------------------
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
2002-07-05 19:21 David Gordon Hogan
2002-07-05 19:52 ` Jim Choate
@ 2002-07-05 20:10 ` Mark Bitting
1 sibling, 0 replies; 103+ messages in thread
From: Mark Bitting @ 2002-07-05 20:10 UTC (permalink / raw)
To: 9fans
On Friday 05 July 2002 15:21, you wrote:
> >>>> Change space! Change the file delimiter!
> >>>> The shell will never recover. The system will break.
> >>>> I will mourn.
> >>>
> >>> Isn't a haiku supposed to have 17 syllables?
> >>
> >> Some would dispute the imposition of such an absolute rule.
> >
> > Is that why your message has only 16 syllables?
>
> Word.
To write a Haiku
of exactly seventeen syllables
is diff.
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
@ 2002-07-05 18:26 Sape Mullender
0 siblings, 0 replies; 103+ messages in thread
From: Sape Mullender @ 2002-07-05 18:26 UTC (permalink / raw)
To: 9fans
>>> Change space! Change the file delimiter!
>>> The shell will never recover. The system will break.
>>> I will mourn.
>>
>> Isn't a haiku supposed to have 17 syllables?
>
> Some would dispute the imposition of such an absolute rule.
Is that why your message has only 16 syllables?
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
@ 2002-07-05 18:23 David Gordon Hogan
0 siblings, 0 replies; 103+ messages in thread
From: David Gordon Hogan @ 2002-07-05 18:23 UTC (permalink / raw)
To: 9fans
>> Change space! Change the file delimiter!
>> The shell will never recover. The system will break.
>> I will mourn.
>
> Isn't a haiku supposed to have 17 syllables?
Some would dispute the imposition of such an absolute rule.
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
@ 2002-07-05 1:21 okamoto
0 siblings, 0 replies; 103+ messages in thread
From: okamoto @ 2002-07-05 1:21 UTC (permalink / raw)
To: 9fans
古池や蛙飛び込む水の音
furu ike ya kawazu tobikomu mizuno oto
Hmmm, it seems to be too long than 17 characters. :-)
Sorry ;_;
Kenji
^ permalink raw reply [flat|nested] 103+ messages in thread
[parent not found: <20020703160003.27491.58783.Mailman@psuvax1.cse.psu.edu>]
* Re: [9fans] blanks in file names
[not found] <20020703160003.27491.58783.Mailman@psuvax1.cse.psu.edu>
@ 2002-07-04 23:35 ` Andrew Simmons
2002-07-04 22:42 ` Sam
2002-07-08 16:14 ` ozan s yigit
0 siblings, 2 replies; 103+ messages in thread
From: Andrew Simmons @ 2002-07-04 23:35 UTC (permalink / raw)
To: 9fans
> Change space! Change the file delimiter!
> The shell will never recover. The system will break.
> I will mourn.
Isn't a haiku supposed to have 17 syllables?
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
2002-07-04 23:35 ` Andrew Simmons
@ 2002-07-04 22:42 ` Sam
2002-07-04 22:44 ` Sam
2002-07-08 16:14 ` ozan s yigit
1 sibling, 1 reply; 103+ messages in thread
From: Sam @ 2002-07-04 22:42 UTC (permalink / raw)
To: 9fans
Yeah, 5, 7, 5, iirc.
Sam
On Fri, 5 Jul 2002, Andrew Simmons wrote:
> > Change space! Change the file delimiter!
> > The shell will never recover. The system will break.
> > I will mourn.
>
> Isn't a haiku supposed to have 17 syllables?
>
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
2002-07-04 22:42 ` Sam
@ 2002-07-04 22:44 ` Sam
0 siblings, 0 replies; 103+ messages in thread
From: Sam @ 2002-07-04 22:44 UTC (permalink / raw)
To: 9fans
Unless that was an attempt at levity, in which case I've just been
caught responding to a thread I haven't been following.
heh,
sam
On Thu,
4 Jul 2002, Sam wrote:
> Yeah, 5, 7, 5, iirc.
>
> Sam
>
> On Fri, 5 Jul 2002, Andrew Simmons wrote:
>
> > > Change space! Change the file delimiter!
> > > The shell will never recover. The system will break.
> > > I will mourn.
> >
> > Isn't a haiku supposed to have 17 syllables?
> >
>
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
2002-07-04 23:35 ` Andrew Simmons
2002-07-04 22:42 ` Sam
@ 2002-07-08 16:14 ` ozan s yigit
1 sibling, 0 replies; 103+ messages in thread
From: ozan s yigit @ 2002-07-08 16:14 UTC (permalink / raw)
To: 9fans
> Isn't a haiku supposed to have 17 syllables?
if you are writing in english, not necessarily. yes if you are writing in
japanese. in that case, it should have seventeen (five/seven/five) *onji*
which is not a syllable, but a sound symbol. these sound symbols are shorter
and more uniform than english syllables. this is is a roundabout way of
saying something many translators and english haiku poets (as i have in
reading and composing haiku for sometime now) found: english haiku needs
only about ten to twelve syllables to have nearly the same duration and
rhythm as a japanese haiku. so don't feel the need to pad a haiku if you
find it sounds right to your ears in ten or thirteen syllables. remember
haiku is unforced, without frills and literary flourishes.
winter moonlight -
little laptop
warm with plan9. [oz/2002]
oz
---
Never let your job get in the way of your work.
-- Sir Isaac Newton, Master of the Royal Mint
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
@ 2002-07-04 12:26 Fco.J.Ballesteros
0 siblings, 0 replies; 103+ messages in thread
From: Fco.J.Ballesteros @ 2002-07-04 12:26 UTC (permalink / raw)
To: 9fans
[-- Attachment #1: Type: text/plain, Size: 702 bytes --]
I'm sorry if in any of my previous mails I did sound
like `Rob did it wrong' or something like that.
I didn't mean that at all, and apologize if that
was what I actually wrote.
I think we all now agree that
-> translating in the mount driver is a bad idea.
-> translating in the servers might work, but we're not sure.
-> %q is a good thing, but,
-> ls et al shouldn't use %q (unless other programs change their conventions
to read file names and digest the quotes properly).
I'm sorry my diff triggered this, but in any case I think we
all are trying to find a way, and more discussions like this will
probably follow.
thanks you all; this has been instructive, at least for me.
[-- Attachment #2: Type: message/rfc822, Size: 1393 bytes --]
From: forsyth@vitanuova.com
To: 9fans@cse.psu.edu
Subject: Re: [9fans] blanks in file names
Date: Thu, 4 Jul 2002 13:20:54 +0100
Message-ID: <20020704122031.530FF19981@mail.cse.psu.edu>
>>So we need an uniform set of conventions, and make all the programs
>>obey them. And that's not the case right now. That's all I was saying
>>regarding %q.
yes, but to be fair, i believe that is the `making the effort' (if i remember the phrase correctly)
that rob mentioned in a previous message!
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
@ 2002-07-04 12:20 forsyth
0 siblings, 0 replies; 103+ messages in thread
From: forsyth @ 2002-07-04 12:20 UTC (permalink / raw)
To: 9fans
>>So we need an uniform set of conventions, and make all the programs
>>obey them. And that's not the case right now. That's all I was saying
>>regarding %q.
yes, but to be fair, i believe that is the `making the effort' (if i remember the phrase correctly)
that rob mentioned in a previous message!
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
@ 2002-07-04 11:37 Fco.J.Ballesteros
0 siblings, 0 replies; 103+ messages in thread
From: Fco.J.Ballesteros @ 2002-07-04 11:37 UTC (permalink / raw)
To: 9fans
: i don't think %q per se is a bad thing, but i don't think filenames
: should require it and hence i don't think tools like ls, pwd, etc
: should output filenames using it.
agree
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
@ 2002-07-04 11:36 rog
0 siblings, 0 replies; 103+ messages in thread
From: rog @ 2002-07-04 11:36 UTC (permalink / raw)
To: 9fans
> Perhaps all this discussion is a symptom that a different convention to
> name files is needed. For example, if file names were always quoted
> (need they to be or not), all programs could rely on a simple set of
> rules to handle file names.
>
> Is there agreement on this? Or is something else I'm also missing?
i don't think %q per se is a bad thing, but i don't think filenames
should require it and hence i don't think tools like ls, pwd, etc
should output filenames using it.
then we're back to where we started (a comfortable place to be IMHO)
except that we have a nice, easily available convention for
serialising arguments containing spaces, and we can talk to alien
filesystems that expect spaces in their names.
rog.
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
@ 2002-07-04 9:50 Fco.J.Ballesteros
0 siblings, 0 replies; 103+ messages in thread
From: Fco.J.Ballesteros @ 2002-07-04 9:50 UTC (permalink / raw)
To: 9fans
[-- Attachment #1: Type: text/plain, Size: 169 bytes --]
So we need an uniform set of conventions, and make all the programs
obey them. And that's not the case right now. That's all I was saying
regarding %q.
thanks
[-- Attachment #2: Type: message/rfc822, Size: 2227 bytes --]
From: forsyth@caldo.demon.co.uk
To: 9fans@cse.psu.edu
Subject: Re: [9fans] blanks in file names
Date: Thu, 4 Jul 2002 10:41:48 +0100
Message-ID: <30a861a9c8a7a63c0e69d46049d70908@caldo.demon.co.uk>
>>Is there agreement on this? Or is something else I'm also missing?
not exactly. i think there's an implication though about the uniform
implementation of quoting rules throughout the system so that
read(filename)
open(dirname + "/" + filename)
would work because `filename' and `dirname' etc haven't any quotes,
because lines read from standard input (say) have been parsed.
some programs do so already but the conventions vary from place to place.
essentially, strings inside programs are in their parsed form and
strings read and written by a program are expected to be suitably quoted.
thus
ls | mumble
would work because mumble will apply the standard rules (might be as simple
as calling tokenize consistently) to each line of its input, and thus unquote it
to reveal the original file names.
i say it's not just file names particularly; for instance, input to a program might
be fields
when where howmuch why who
allowing
15/9/1660 London 4d 'First Cup of Tea' 'Saml Pepys'
and with suitable changes comm, sort, etc. could be applied in obvious ways.
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
@ 2002-07-04 9:41 forsyth
0 siblings, 0 replies; 103+ messages in thread
From: forsyth @ 2002-07-04 9:41 UTC (permalink / raw)
To: 9fans
>>Is there agreement on this? Or is something else I'm also missing?
not exactly. i think there's an implication though about the uniform
implementation of quoting rules throughout the system so that
read(filename)
open(dirname + "/" + filename)
would work because `filename' and `dirname' etc haven't any quotes,
because lines read from standard input (say) have been parsed.
some programs do so already but the conventions vary from place to place.
essentially, strings inside programs are in their parsed form and
strings read and written by a program are expected to be suitably quoted.
thus
ls | mumble
would work because mumble will apply the standard rules (might be as simple
as calling tokenize consistently) to each line of its input, and thus unquote it
to reveal the original file names.
i say it's not just file names particularly; for instance, input to a program might
be fields
when where howmuch why who
allowing
15/9/1660 London 4d 'First Cup of Tea' 'Saml Pepys'
and with suitable changes comm, sort, etc. could be applied in obvious ways.
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
@ 2002-07-04 8:31 Fco.J.Ballesteros
0 siblings, 0 replies; 103+ messages in thread
From: Fco.J.Ballesteros @ 2002-07-04 8:31 UTC (permalink / raw)
To: 9fans
> it would be good to have some simple but consistent conventions for quoting data,
> not particularly file names. it's true that it would probably affect many commands
> (sort, sed, awk etc) but i think it might be worthwhile.
I'd like the file names to be always the same. What I don't like about
%q is that some times you get /a/b and other times you get '/a/b c'.
This is a serious problem IMHO, since the "'" would make open fail.
I'd like
read(filename)
open(filename)
and
read(filename)
open(dirname + "/" + filename)
to keep on working, which is no longer the case after %q. (Didn't check
naming in the kernel recently, but I think these calls would fail).
Perhaps all this discussion is a symptom that a different convention to
name files is needed. For example, if file names were always quoted
(need they to be or not), all programs could rely on a simple set of
rules to handle file names.
Is there agreement on this? Or is something else I'm also missing?
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
@ 2002-07-04 8:22 forsyth
0 siblings, 0 replies; 103+ messages in thread
From: forsyth @ 2002-07-04 8:22 UTC (permalink / raw)
To: 9fans
>>: should be the character in the name, the quoting approach seems
>>: the only one that works properly, and we have some work to do
>>: to work out all the interactions with shell scanning (oh dear!), and changing
>>But it's not just the shell, almost *any* program reading file names would
>>have to deal with quoting. What has been a file name is changing after %q,
you stopped the quote just a little early:
to work out all the interactions with shell scanning (oh dear!), and changing
-> (i suspect) the input conventions of quite a few commands, but still, it's a finite task.
but i ought to have said `the input [and output] conventions ...'
it would be good to have some simple but consistent conventions for quoting data,
not particularly file names. it's true that it would probably affect many commands
(sort, sed, awk etc) but i think it might be worthwhile.
it's something that XML can't do properly for instance.
just amazing. all that effort for a revolution, and botched at the start.
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
@ 2002-07-04 7:53 Fco.J.Ballesteros
0 siblings, 0 replies; 103+ messages in thread
From: Fco.J.Ballesteros @ 2002-07-04 7:53 UTC (permalink / raw)
To: 9fans
That's important since I may have names like
'a b' and 'a_b', both legal, and your translation
would get into throuble here.
> Hello,
>
>>You can't do that becaause if a file contains a genuine
>>underscore, the outgoing software will think it's a space.
> the outgoing software will also think it's a underscaore.
> Is this important?
> Some OSs already map 'Windows' to 'WINDOWS'.
>
> Kenji Arisawa
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
@ 2002-07-04 7:47 Fco.J.Ballesteros
0 siblings, 0 replies; 103+ messages in thread
From: Fco.J.Ballesteros @ 2002-07-04 7:47 UTC (permalink / raw)
To: 9fans
forsyth:
: the problem rob alluded to, by analogy with NAT, should not
: arise within the Plan 9 system. for instance, if i have a file
: of file names, can i read it in and be sure to access those names?
: if space is _ and _ is `boo!' it's anyone's guess.
But space is not _, space is space.
As I said in a previous mail, if you have a file of file names,
you can still read and use it. AFAIK, you can be sure to access those
names.
Nevertheless, I can understand your arguments for doing it at
boundaries and not at the kernel.
: should be the character in the name, the quoting approach seems
: the only one that works properly, and we have some work to do
: to work out all the interactions with shell scanning (oh dear!), and changing
But it's not just the shell, almost *any* program reading file names would
have to deal with quoting. What has been a file name is changing after %q,
before that, a program would expect something like [/]a/b/..., that's no longer
the case.
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
@ 2002-07-04 6:34 forsyth
2002-07-04 7:39 ` Lucio De Re
0 siblings, 1 reply; 103+ messages in thread
From: forsyth @ 2002-07-04 6:34 UTC (permalink / raw)
To: 9fans
[-- Attachment #1: Type: text/plain, Size: 3315 bytes --]
the advantage of pushing stuff like this back to the boundaries,
the points at which Plan 9 interacts with other systems and formats
(often using 9P), rather than building it into the heart of Plan 9, is that
at least the Plan 9 system itself can have straightforward internal rules.
at the boundaries you're bound to be aware that there
are differences (in practice). for instance, you can create
names via dossrv that Windows itself cannot access properly
(left as an exercise for the reader), but aren't prohibited by
the FAT32 specification, or indeed, documented accurately
anywhere. it's only a little better with 9660srv.
the problem rob alluded to, by analogy with NAT, should not
arise within the Plan 9 system. for instance, if i have a file
of file names, can i read it in and be sure to access those names?
if space is _ and _ is `boo!' it's anyone's guess.
it's more understandable if, when problems do arise, they appear only at
the boundaries with other systems, where there are necessarily
some differences (remembering of course that any given difference might or
might not be strictly `necessary').
so far, it seems to me:
if Plan 9 allows space directly in the storage names, then space
should be the character in the name, the quoting approach seems
the only one that works properly, and we have some work to do
to work out all the interactions with shell scanning (oh dear!), and changing
(i suspect) the input conventions of quite a few commands, but still, it's a finite task.
the possible scale of that task--even understanding all the implications--
can i think be underestimated, which is why i snarl a bit at
people who are incredibly glib about it [which rob is not].
otherwise, Plan 9 should prohibit space in its file names, as
previously, and the user interface can use something like U+00A0 to
provide the functionality that at least some humans seem to think is
essential. (computers don't give a dam whether names have spaces or
not.) at the boundaries with Windows or Mac or Unix that character can
be mapped to and fro, but there is already mapping of various sorts
taking place there. (Windows itself has trouble enough with its
conventions; another little exercise: what is a file name separator
under Windows and how do you use it?) to return to the file name list
example, it's less surprising that Plan 9 can't take a list of file in
Windows style and access them directly. that wouldn't work whether
space were allowed or not. Plan 9 already does translate at
the boundaries between UTF-8 and whatever the other system uses.
the latter approach handles not just space but also some other
characters such as `/' that turn up at the boundaries, but cannot be
handled by Plan 9. again, some are glib about the need for it,
and i snarl again. even so, pragmatically there's no need to use one technique
for everything if space is regarded as utterly different from all
other such characters. space could be used as itself within the system
and we can map `/' as and when we find it.
it's also worth noting that having consistent quoting conventions to allow spaces
in space-separated input is probably worthwhile on its own, so not all
the work in Plan A will vanish. don't quit that editor just yet.
[-- Attachment #2: Type: message/rfc822, Size: 1658 bytes --]
To: 9fans@cse.psu.edu
Subject: Re: [9fans] blanks in file names
Date: Thu, 4 Jul 2002 07:10:55 +0900
Message-ID: <20020703221118.15154199B7@mail.cse.psu.edu>
Hello,
>You can't do that becaause if a file contains a genuine
>underscore, the outgoing software will think it's a space.
the outgoing software will also think it's a underscaore.
Is this important?
Some OSs already map 'Windows' to 'WINDOWS'.
Kenji Arisawa
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
2002-07-04 6:34 forsyth
@ 2002-07-04 7:39 ` Lucio De Re
2002-07-04 9:32 ` Nikolai SAOUKH
0 siblings, 1 reply; 103+ messages in thread
From: Lucio De Re @ 2002-07-04 7:39 UTC (permalink / raw)
To: 9fans
On Thu, Jul 04, 2002 at 07:34:25AM +0100, forsyth@caldo.demon.co.uk wrote:
>
> the problem rob alluded to, by analogy with NAT, should not
> arise within the Plan 9 system. for instance, if i have a file
> of file names, can i read it in and be sure to access those names?
> if space is _ and _ is `boo!' it's anyone's guess.
>
I think we're going somewhere <grin>
We already have shims between the conventional Plan 9 filesystem
and foreign ones. These are our declared boundaries and it is
fairly clear what translations are required at each of these
boundaries.
It seems to me that Nemo is - perhaps unintentionally, certainly
not in an explicit fashion - creating an inner boundary that declares
the core of Plan 9 much more liberal and a shim is therefore
necessary so that the existing legacy applications can interact
with it.
I would vote for such a feature. The kernel and 9P would be freed
of filename shackles, the shim would apply the existing rules.
Imagine, for example, a shim that would enable a 2nd Edition
application to access the 4th Edition filesystem. Mapping filenames
to unique 27-character UTF8 strings with certain restrictions should
be possible through such a shim.
Even the choice of delimiter between path components would be
available to those willing to produce the necessary shim.
++L
PS: while checking the above, I was wondering where %q belongs in
that model. I would think the shim must somehow provide the actual
quote and dequote operations. Hm, maybe such a shim can also add
descriptive names and, shudder, access control lists in a Plan 9
friendly form.
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
@ 2002-07-03 8:00 Fco.J.Ballesteros
2002-07-03 12:00 ` Lucio De Re
0 siblings, 1 reply; 103+ messages in thread
From: Fco.J.Ballesteros @ 2002-07-03 8:00 UTC (permalink / raw)
To: 9fans
rog@vitanuova.com :
: /sys/src/cmd/dossrv
: /sys/src/cmd/9660srv
: /sys/src/cmd/tapefs
: /sys/src/cmd/unix/u9fs
: /sys/src/cmd/ftpfs
: convert "space char" to/from external actual space on create,
: walk, wstat, stat and directory reads.
One crazy idea I had was to do that translation in the mount driver.
That way the server would be happy to think that it uses space, and
the client plan 9 program would be happy to see 00A0 or whatever
without confussion with the space character.
lucio@proxima.alt.za :
: What I'm saying, is that I'd like to target a kernel that is entirely
: delimiter agnostic and promote each user application in the same
: direction as a long-term project. In the interim, constructs that
: cast delimiters in stone should be removed wherever possible.
IMHO, the problem is mostly the user programs and not the kernel.
AFAIK, the kernel is fine if you don't use / and \0 as delimiters
(which seems reasonable to me, although some guys might want to use it too).
But the tradition that blanks separate arguments is deeply embedded in
user programs, perhaps most notably the shell.
Assume the kernel has changed to use openv[], what would the shell
do to deal with spaces vs 00A0s ?
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
2002-07-03 8:00 Fco.J.Ballesteros
@ 2002-07-03 12:00 ` Lucio De Re
2002-07-03 19:39 ` rob pike, esq.
0 siblings, 1 reply; 103+ messages in thread
From: Lucio De Re @ 2002-07-03 12:00 UTC (permalink / raw)
To: 9fans
*** ramble alert! ***
On Wed, Jul 03, 2002 at 10:00:55AM +0200, Fco.J.Ballesteros wrote:
>
> IMHO, the problem is mostly the user programs and not the kernel.
> AFAIK, the kernel is fine if you don't use / and \0 as delimiters
> (which seems reasonable to me, although some guys might want to use it too).
>
Yes, it would be convenient for the delimiter to be soft, for example.
> But the tradition that blanks separate arguments is deeply embedded in
> user programs, perhaps most notably the shell.
>
I certainly will not argue with this.
> Assume the kernel has changed to use openv[], what would the shell
> do to deal with spaces vs 00A0s ?
>
Well, it's not as if I'm the genius here :-)
The command line (ignore the shell for a moment as its interpreter)
is a very clear expression of the user's intent, in that there is
a long tradition behind it and, eqaully important(ly), it is visually
unambiguous (within human limits). The feature one often overlooks
of spaces is that they can be repeated with no change of semantics
or replaced by other whitespace with similar results (cf. sendmail's
configuration file and its tab/space madness).
So it would seem reasonable to retain the convention unchanged in
the familiar contexts and seek alternatives in the new, graphical
environments, for example. Is there perhaps an undiscovered
technique to express a shell pipeline in a graphical format? If
so, can new separator rules be brought to apply, escaping some of
the limitations of the traditional approach?
Maybe facetiously, I'd like to point out that the space is the
absence of a character to the eye, if we used a typescript interface
with pixel-dots in the character positions, drag-and-dropping
command line parameters would be automatically quoted by the
background pixel-dots. That is, until you want a pixel-dot character
in an argument. Sigh.
Still, a background of single quotes would work and be horrendously
ugly, argument completion may become mandatory as the shell now no
longer can provide that function as everything is quoted.
In short, no, I do not have an answer for Nemo, but it seems to me
that bending the conventional interface is not going to work well,
we ought to be looking for new answers, not unlike the ingeniousness
that brought us Plan 9 in the first place and acme as the most
extreme example.
++L
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
2002-07-03 12:00 ` Lucio De Re
@ 2002-07-03 19:39 ` rob pike, esq.
2002-07-07 4:02 ` Dave
0 siblings, 1 reply; 103+ messages in thread
From: rob pike, esq. @ 2002-07-03 19:39 UTC (permalink / raw)
To: 9fans
You guys are all arguing about system stuff but it's the
*user interface* that you're really arguing about, and
breaking. You are opening a can of worms you will never
get closed again. Change space! Change the file delimiter!
The shell will never recover. The system will break.
I will mourn.
-rob
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
2002-07-03 19:39 ` rob pike, esq.
@ 2002-07-07 4:02 ` Dave
2002-07-07 5:17 ` arisawa
2002-07-08 9:48 ` Boyd Roberts
0 siblings, 2 replies; 103+ messages in thread
From: Dave @ 2002-07-07 4:02 UTC (permalink / raw)
To: 9fans
How about representing paths internally as connected structures (linked lists, if you will), each of which identifies a particular node. The method of representation of a given node can be quite flexible (allowing node completion - or as I would term it, cannonization - to be done by the kernel), and user programs could establish their own conventions for dealing with user input and user output (which seems logical to me, since the kernel really isn't intended to be a human user interface, only a program "user" interface).
Here's an off-the-top-of-my-head example to illustrate what I mean. I'm sure we can come up with a much better system if we all think about this a bit, and figure out how it can be improved (or how it can be replaced with something even better - the purpose of this example is simply to get us thinking in a particular direction that I believe is quite promising):
struct node_t {
char* name; size_t name_l; /* the node name, and the length of the name */
/* An error should probably be returned by the kernel if hint is ambiguous. */
char* hint; /* a regexp that can be fed to attempt to "autocomplete" */
size_t inode; /* another unique identifier for a node - should we allow it? */
node_t* next_node;
};
/* canonize(2) converts a node_t chain into its canonical form, expanding all
* hints into the corresponding names. If there are any possible
* canonizations and dst is not NULL, dst is filled with node_t chains
* representing all the possible canonizations of the node_t chain given.
* PARAMETERS
* src is the node_t chain that you're attempting to canonize. It's probably
* obtained by parsing the input to our shell, and deciding how to interpret
* it.
* On calling canonize(2), dst should point to a memory block large enough to
* accomodate *dst_l node_t structs. canonize(2) will use the memory block to
* store all the nodes of all the node_t chains it creates.
* On return from canonize(2), dst_l will be changed to the number of node_t
* chains representing possible canonizations (i.e., it's a value-result
* parameter), and the first dst_l locations in dst will contain the starting
* nodes of the node_t chains representing the possible canonizations.
* RETURN VALUE
* 0 on success
* -1 on failure, with errno set appropriately
* Multiple matches is counted as an error condition, since canonize(2) failed
* to canonize the node_t chain.
* If dst is too small, dst will be filled as much as possible, but an error
* will still be returned.
* NOTES
* Having the self-referencing pointer in node_t refer to the previous node
* instead of the next node would allow canonize(2) to save lots of buffer
* space in dst for ambiguities that occur deep inside a long node_t chain.
* However, I don't believe we should do that, since (a) ambiguities that
* occur relatively early in a long node_t chain allow canonize(2) to save
* lots of buffer space in dst in the current implementation; and more
* importantly, (b) any other routine in the kernel that deals with node_t
* chains will have to walk the entire linked list before processing anything
* if we implement that change, since the pointer it'll see won't be to the
* start of the "pathname," but rather to the end.
*/
int canonize (const node_t* src, node_t dst[], size_t* dst_l);
int new_open (const node_t* path, int flags, int mode);
/* The old open(2) can instead become open(3), with a rather trivial
* implementation:
* int open (const char* path, int flags, int mode) {
* split path on unescaped '/' chars;
* create a node_t for each of the components obtained above;
* link the nodes together into a chain;
* return openv(our_node_t_chain,flags,mode);
* };
*/
/* Here's one final example - the reason I resist the name openv(2): */
int new_execve (const node_t* path, char* const argv[], char* const envp[]);
/* The "v" here refers to a different aspect of the function. I don't like
* overloading the meaning, because we'd have to call our new execve(2)
* execvev(2) or something, and that'd be a little insane, IMHO. That's why I
* chose the "new_" prefix.
* In reality, I'd much rather see the old open(2) be renamed to old_open(2),
* and have the new_open(2) be renamed to just plain open(2), damning backward
* compatibility (and likewise with the exec(2) family, as well as the stat(2)
* call, etc.). Programs that expect open(2) to be the old open and don't feel
* like asking their authors for a rewrite can simply use a runtime library to
* rename old_open(2) to open(2) and hide our new open(2) entirely (since
* they're obviously not going to use it, anyway). However, I'm afraid this
* type of drastic change may catch some people off-guard.
*/
Dave Cohen <dave@dave.tj>
rob pike, esq. wrote:
>
> You guys are all arguing about system stuff but it's the
> *user interface* that you're really arguing about, and
> breaking. You are opening a can of worms you will never
> get closed again. Change space! Change the file delimiter!
> The shell will never recover. The system will break.
> I will mourn.
>
> -rob
>
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
2002-07-07 4:02 ` Dave
@ 2002-07-07 5:17 ` arisawa
[not found] ` <"arisawa@ar.aichi-u.ac.jp"@Jul>
2002-07-08 9:48 ` Boyd Roberts
1 sibling, 1 reply; 103+ messages in thread
From: arisawa @ 2002-07-07 5:17 UTC (permalink / raw)
To: 9fans
If '/' is prohibitted as an element of file name and directory name,
then no change to open is required.
Let's assume we accept '/' as an element of names,
then how do you express path in rc?
/bin/awk may be :
1. /bin/awk as it has been.
2. a file named "/bin/awk" in current directory.
3. a file named "bin/awk" in "/"
4. a file named "awk" in "/bin" and "/bin" is in current directory.
Kenji Arisawa
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
2002-07-07 4:02 ` Dave
2002-07-07 5:17 ` arisawa
@ 2002-07-08 9:48 ` Boyd Roberts
2002-07-08 20:22 ` Dave
2002-07-08 23:05 ` Berry Kercheval
1 sibling, 2 replies; 103+ messages in thread
From: Boyd Roberts @ 2002-07-08 9:48 UTC (permalink / raw)
To: 9fans
Dave wrote:
> The method of representation of a given node can be quite flexible
> (allowing node completion - or as I would term it, cannonization
> - to be done by the kernel),
I thought the making of saints wasn't exactly in the kernel's job
description.
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
2002-07-08 9:48 ` Boyd Roberts
@ 2002-07-08 20:22 ` Dave
2002-07-09 8:24 ` Boyd Roberts
2002-07-08 23:05 ` Berry Kercheval
1 sibling, 1 reply; 103+ messages in thread
From: Dave @ 2002-07-08 20:22 UTC (permalink / raw)
To: 9fans
It's possible that cannonization should still be done by library routines,
but I'd vote to let the kernel do it anyway for whatever optimizations
it can make (since it's not restricted to the standard syscalls for
file handling).
- Dave
Boyd Roberts wrote:
>
> Dave wrote:
> > The method of representation of a given node can be quite flexible
> > (allowing node completion - or as I would term it, cannonization
> > - to be done by the kernel),
>
> I thought the making of saints wasn't exactly in the kernel's job
> description.
>
>
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
2002-07-08 9:48 ` Boyd Roberts
2002-07-08 20:22 ` Dave
@ 2002-07-08 23:05 ` Berry Kercheval
1 sibling, 0 replies; 103+ messages in thread
From: Berry Kercheval @ 2002-07-08 23:05 UTC (permalink / raw)
To: 9fans
Boyd Roberts <boyd@strakt.com> writes:
> Dave wrote:
> > The method of representation of a given node can be quite flexible
> > (allowing node completion - or as I would term it, cannonization
> > - to be done by the kernel),
>
> I thought the making of saints wasn't exactly in the kernel's job
> description.
Naw, making saints is "canonization". Making artillery is a perfectly
good kernel task.
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
@ 2002-07-02 18:14 rog
2002-07-02 23:08 ` Dan Cross
0 siblings, 1 reply; 103+ messages in thread
From: rog @ 2002-07-02 18:14 UTC (permalink / raw)
To: 9fans
> - change the system to translate blanks in file names to the
> same character.
it might be worth identifying the exact points that would need changing
should such a scheme be chosen.
/sys/src/cmd/dossrv
/sys/src/cmd/9660srv
/sys/src/cmd/tapefs
/sys/src/cmd/unix/u9fs
/sys/src/cmd/ftpfs
convert "space char" to/from external actual space on create,
walk, wstat, stat and directory reads.
/sys/src/9/port/latin1.c
make it possible to have a single character ALT sequence
(if ALT-space is what's desired).
> - change the quote library so it does not quote that character.
it doesn't matter if it does...
however various places would need to change back so they didn't quote
chars (e.g. ls, pwd?)
a suitable character would need to be chosen (e.g. 00A0), and it
would be nice if most fonts displayed it in a reasonably consistent
manner.
perhaps a new function could be added to libc that does the
conventional conversion from ' ' to the new space char so that
programs with GUI entry boxes that know that a string is being typed
in a filename context can trivially do the conversion.
what have i missed?
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
2002-07-02 18:14 rog
@ 2002-07-02 23:08 ` Dan Cross
0 siblings, 0 replies; 103+ messages in thread
From: Dan Cross @ 2002-07-02 23:08 UTC (permalink / raw)
To: 9fans
> /sys/src/9/port/latin1.c
Speaking of this.... Is there a good reason to leave latin1 in the
kernel, and not pull it up into libc? I suggested this once before,
and Russ didn't want to move it since it's most frequently used in the
kernel. However, it seems silly to me that it's not in bitsy/keyboard,
for one, and anyone who wants to write a keyboard-like application
would want to avail themselves of it. For instance, I was working on a
Targus keyboard driver, and had to copy it out of the kernel to link
against.
- Dan C.
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
@ 2002-07-02 11:09 forsyth
2002-07-02 11:53 ` matt
0 siblings, 1 reply; 103+ messages in thread
From: forsyth @ 2002-07-02 11:09 UTC (permalink / raw)
To: 9fans
>>rog@vitanuova.com wrote:
>> the benefits of converting to utf-8 throughout were obvious. does the
>> ability to type ' ' rather than (say) ALT-' ' really confer comparable
>> advantages?
>The benefits of any feature depend on whether you make use of them.
>People living in an ASCII world get no particular benefit from UTF8,
>and people with spaces in file names (e.g. on a Windows filesystem)
>get substantial benefit from having their files handled properly.
no one is suggesting, least of all roger, that nothing be done to
allow access to files between Plan 9 and systems that have spaces in names.
the disagreement is about the scope, and the means.
>>In any case, I agree that blanks are here to stay and I'd like Plan 9
>>to handle then as nicely as it handles .
it's not just spaces. i have had to handle / as well, for instance.
that might not be of interest to some, but it has occurred.
from an end user's point of view, it seems perfectly reasonable to me.
i'd also pick out something from a previous comment:
>>Plan 9 to Unicode and UTF: too hard, too much code to change, too many
>>symmetries broken. But there's no way this problem is as hard as that
>>conversion, and we handled that one just fine. All that's missing is
surely it was much easier to do once the problems of Unicode's
original 8-bit representation pre-UTF had been dealt with:
In August 1992, X-Open circulated a proposal for another UTF-like byte
encoding of Unicode characters. Their major concern was that an
embedded character in a file name (in particular a slash) could be
part of an escape sequence in UTF and therefore confuse a traditional
file system.
that single change to UTF made it more straightforward to work out where
the potential problems were, not least some older code could no longer fail (as it
would have done with the earlier proposal):
p = strrchr(filename, '/');
for instance. prior to that, each such instance needed to be tracked down
and examined, assuming (on non-Plan9 systems) that source was available.
of course, larger changes were required to tools that needed to support Unicode
well (regexp, tr, wc, and so on). still, with many potential possibilities
for mechanical confusion eliminated at a stroke, i'd say it instantly made the
idea attractive. there were not as many problems to worry about.
i do think the support for quoting is useful for many things (roger added support for quoting to
Inferno's String module several years ago for just that reason), but i'm not sure myself
it's the right or sufficient solution for file names.
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
2002-07-02 11:09 forsyth
@ 2002-07-02 11:53 ` matt
2002-07-02 13:29 ` Boyd Roberts
2002-07-02 18:28 ` plan9
0 siblings, 2 replies; 103+ messages in thread
From: matt @ 2002-07-02 11:53 UTC (permalink / raw)
To: 9fans
> it's not just spaces. i have had to handle / as well, for instance.
> that might not be of interest to some, but it has occurred.
Reserved characters in filename conventions seem to me to be archaic.
I often use spaces in my filenames, they are human
The directory separator for instance is in band signalling.
If I can quote Douglas A Gwyn here * :
"For example, I take it as one more example of the evil of stealing
perfectly legitimate code values for in-band control purposes."
Being unable to use / as part of a filename is burdensome when it comes to
"interesting" file servers.
For instance one of my daydreams is the IRC fileserver with the channel name
as a directory but many many channels use / in their channel names. (In fact
many people go out of their way to cram as many special characters into IRC
channel names as possible).
I've wondered if it was possible to define the path separator on a per
process basis or something.
Perhaps you can already?
matt
*
http://groups.google.com/groups?q=in+band+group:comp.os.plan9&hl=en&lr=&ie=U
TF-8&selm=3CCE1366.EAB27A38%40null.net&rnum=2
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
2002-07-02 11:53 ` matt
@ 2002-07-02 13:29 ` Boyd Roberts
2002-07-02 14:57 ` FJ Ballesteros
2002-07-02 18:28 ` plan9
1 sibling, 1 reply; 103+ messages in thread
From: Boyd Roberts @ 2002-07-02 13:29 UTC (permalink / raw)
To: 9fans
Seems like GNU have a 'solution':
NAME
xargs - build and execute command lines from standard input
SYNOPSIS
xargs [-0prtx] [-e[eof-str]] [-i[replace-str]] [-l[max-lines]] [-n
max-args] [-s max-chars] [-P max-procs] [--null] [--eof[=eof-str]]
[--replace[=replace-str]] [--max-lines[=max-lines]] [--interactive]
[--max-chars=max-chars] [--verbose] [--exit] [--max-procs=max-procs]
[--max-args=max-args] [--no-run-if-empty] [--version] [--help] [com
mand [initial-arguments]]
DESCRIPTION
This manual page documents the GNU version of xargs. xargs reads
arguments from the standard input, delimited by blanks (which can be
protected with double or single quotes or a backslash) or newlines,
and executes the command (default is /bin/echo) one or more times
with any initial-arguments followed by arguments read from standard
input. Blank lines on the standard input are ignored.
xargs exits with the following status:
0 if it succeeds
123 if any invocation of the command exited with status 1-125
124 if the command exited with status 255
125 if the command is killed by a signal
126 if the command cannot be run
127 if the command is not found
1 if some other error occurred.
Some characters were just not meant to be in filenames, which would avoid the
above.
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
2002-07-02 13:29 ` Boyd Roberts
@ 2002-07-02 14:57 ` FJ Ballesteros
2002-07-02 16:23 ` Lucio De Re
2002-07-03 19:21 ` rob pike, esq.
0 siblings, 2 replies; 103+ messages in thread
From: FJ Ballesteros @ 2002-07-02 14:57 UTC (permalink / raw)
To: 9fans
>
> Some characters were just not meant to be in filenames, which would avoid the
> above.
But they are, even in my system there're many files with blanks on their
names
(and I never choose such names).
Since IFAIK none of the authors have anything against the proposal
that came out of 9fans (see my previous post, where I tried to summarize
it),
what if I change the source just to do it?
- let Alt-spc generate our unicode blank character
- change the system to translate blanks in file names to the
same character.
- change the quote library so it does not quote that character.
I don't have much time right know and that's why I ask before changing
the
code. I'm willing to implement it if there's agreement, so please, don't
ignore the proposal just becase there's no code attached by now,
just let me know.
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
2002-07-02 14:57 ` FJ Ballesteros
@ 2002-07-02 16:23 ` Lucio De Re
2002-07-03 19:21 ` rob pike, esq.
1 sibling, 0 replies; 103+ messages in thread
From: Lucio De Re @ 2002-07-02 16:23 UTC (permalink / raw)
To: 9fans
On Tue, Jul 02, 2002 at 04:57:18PM +0200, FJ Ballesteros wrote:
> >
> > Some characters were just not meant to be in filenames, which would avoid the
> > above.
>
> But they are, even in my system there're many files with blanks on their
> names
> (and I never choose such names).
>
I prefer the suggested option of an open(2) (openv?) that takes a
strings vector instead of a slash-delimited path. It seems to me
that such an approach is still viable as an objective and it would
be expedient to keep it in mind and avoid developments that might
defeat it.
What I'm saying, is that I'd like to target a kernel that is entirely
delimiter agnostic and promote each user application in the same
direction as a long-term project. In the interim, constructs that
cast delimiters in stone should be removed wherever possible.
Of course, I may be talking about a completely different operating
system, but it strikes me that Plan 9 is the most suitable foundation
for such a thing and its developers' abilities certainly (in my
opinion) unmatched, so why not start there?
++L
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
2002-07-02 14:57 ` FJ Ballesteros
2002-07-02 16:23 ` Lucio De Re
@ 2002-07-03 19:21 ` rob pike, esq.
2002-07-03 14:31 ` FJ Ballesteros
1 sibling, 1 reply; 103+ messages in thread
From: rob pike, esq. @ 2002-07-03 19:21 UTC (permalink / raw)
To: 9fans
Because file names come in places other than directories. You
can't always get this right. If you translate them going into
open(), you will be inconsistent with file names used other ways.
It's similar to the problem with NAT boxes and hidden IP addresses.
I'd say do nothing yet. There is no clear right answer.
-rob
--On Tuesday, July 02, 2002 4:57 PM +0200 FJ Ballesteros
<nemo@gsyc.escet.urjc.es> wrote:
>>
>> Some characters were just not meant to be in filenames, which would
>> avoid the above.
>
> But they are, even in my system there're many files with blanks on their
> names
> (and I never choose such names).
>
> Since IFAIK none of the authors have anything against the proposal
> that came out of 9fans (see my previous post, where I tried to summarize
> it),
> what if I change the source just to do it?
>
> - let Alt-spc generate our unicode blank character
> - change the system to translate blanks in file names to the
> same character.
> - change the quote library so it does not quote that character.
>
> I don't have much time right know and that's why I ask before changing
> the
> code. I'm willing to implement it if there's agreement, so please, don't
> ignore the proposal just becase there's no code attached by now,
> just let me know.
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
2002-07-03 19:21 ` rob pike, esq.
@ 2002-07-03 14:31 ` FJ Ballesteros
0 siblings, 0 replies; 103+ messages in thread
From: FJ Ballesteros @ 2002-07-03 14:31 UTC (permalink / raw)
To: 9fans
Well, I agree, but since I got your mail after a tiny spare-time bucket,
I already
tried it and sent the diff.
And now that I have been playing with it for a while, I have
started to love it, sic.
Regarding the inconsistence, I think that most of the cases
are still handled by the side-effect that 'a x' is still
understood as 'a x'. Although not fully consistent, I don't know
a better way.
"rob pike, esq." ha escrito:
>
> Because file names come in places other than directories. You
> can't always get this right. If you translate them going into
> open(), you will be inconsistent with file names used other ways.
> It's similar to the problem with NAT boxes and hidden IP addresses.
>
> I'd say do nothing yet. There is no clear right answer.
>
> -rob
>
> --On Tuesday, July 02, 2002 4:57 PM +0200 FJ Ballesteros
> <nemo@gsyc.escet.urjc.es> wrote:
>
> >>
> >> Some characters were just not meant to be in filenames, which would
> >> avoid the above.
> >
> > But they are, even in my system there're many files with blanks on their
> > names
> > (and I never choose such names).
> >
> > Since IFAIK none of the authors have anything against the proposal
> > that came out of 9fans (see my previous post, where I tried to summarize
> > it),
> > what if I change the source just to do it?
> >
> > - let Alt-spc generate our unicode blank character
> > - change the system to translate blanks in file names to the
> > same character.
> > - change the quote library so it does not quote that character.
> >
> > I don't have much time right know and that's why I ask before changing
> > the
> > code. I'm willing to implement it if there's agreement, so please, don't
> > ignore the proposal just becase there's no code attached by now,
> > just let me know.
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
2002-07-02 11:53 ` matt
2002-07-02 13:29 ` Boyd Roberts
@ 2002-07-02 18:28 ` plan9
2002-07-03 13:54 ` arisawa
1 sibling, 1 reply; 103+ messages in thread
From: plan9 @ 2002-07-02 18:28 UTC (permalink / raw)
To: 9fans
On Tue, Jul 02, 2002 at 12:53:16PM +0100, matt wrote:
>
> I often use spaces in my filenames, they are human
Do they all go down to the Space Bar and get pounded after work?
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
2002-07-02 18:28 ` plan9
@ 2002-07-03 13:54 ` arisawa
2002-07-03 14:24 ` FJ Ballesteros
` (2 more replies)
0 siblings, 3 replies; 103+ messages in thread
From: arisawa @ 2002-07-03 13:54 UTC (permalink / raw)
To: 9fans
Hello,
I prefer spaces are mapped simplly to underscores.
Then
term% touch 'some files'
create some_files
and
term% rm 'some files'
removes some_files
However, I don't think these defects are practically important.
I am rather afraid Plan9 loses simplicity.
Kenji Arisawa
E-mail: arisawa@aichi-u.ac.jp
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
2002-07-03 13:54 ` arisawa
@ 2002-07-03 14:24 ` FJ Ballesteros
2002-07-03 19:40 ` rob pike, esq.
2002-07-04 8:30 ` Ralph Corderoy
2 siblings, 0 replies; 103+ messages in thread
From: FJ Ballesteros @ 2002-07-03 14:24 UTC (permalink / raw)
To: 9fans
I wouldn't say this change makes the system more complex,
one thing I found after playing with this
is that even though I made no change
to the quote stuff in the C library, programs started to
handle funny file names without relying on %q.
This is the semantics for the thing I sent before:
both touch 'a x' and touch 'a\0xa0x'
would create a file named 'a x'
Thus in both cases, ls would get
'a\0x00a0x'
Besides, foreign systems would still see 'a x'
(Im sorry, but don't know how to type Alt X 00A0 under windows,
\x00a0 above should be read like our non-break space character).
Regarding what you say about "_", I'd still like to be able
to type "touch a_x.c". IMHO, the
character of choice doesn't matter to much, but I think
it would be better if it's not an already used character.
arisawa@ar.aichi-u.ac.jp ha escrito:
>
> Hello,
>
> I prefer spaces are mapped simplly to underscores.
> Then
> term% touch 'some files'
> create some_files
> and
> term% rm 'some files'
> removes some_files
> However, I don't think these defects are practically important.
> I am rather afraid Plan9 loses simplicity.
>
> Kenji Arisawa
> E-mail: arisawa@aichi-u.ac.jp
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
2002-07-03 13:54 ` arisawa
2002-07-03 14:24 ` FJ Ballesteros
@ 2002-07-03 19:40 ` rob pike, esq.
2002-07-03 22:10 ` arisawa
2002-07-04 8:30 ` Ralph Corderoy
2 siblings, 1 reply; 103+ messages in thread
From: rob pike, esq. @ 2002-07-03 19:40 UTC (permalink / raw)
To: 9fans
You can't do that becaause if a file contains a genuine
underscore, the outgoing software will think it's a space.
-rob
--On Wednesday, July 03, 2002 10:54 PM +0900 arisawa@ar.aichi-u.ac.jp wrote:
> Hello,
>
> I prefer spaces are mapped simplly to underscores.
> Then
> term% touch 'some files'
> create some_files
> and
> term% rm 'some files'
> removes some_files
> However, I don't think these defects are practically important.
> I am rather afraid Plan9 loses simplicity.
>
> Kenji Arisawa
> E-mail: arisawa@aichi-u.ac.jp
^ permalink raw reply [flat|nested] 103+ messages in thread
* Re: [9fans] blanks in file names
2002-07-03 13:54 ` arisawa
2002-07-03 14:24 ` FJ Ballesteros
2002-07-03 19:40 ` rob pike, esq.
@ 2002-07-04 8:30 ` Ralph Corderoy
2 siblings, 0 replies; 103+ messages in thread
From: Ralph Corderoy @ 2002-07-04 8:30 UTC (permalink / raw)
To: 9fans
> term% rm 'some files'
> removes some_files
Hark! The scent of DWIM.
http://www.tuxedo.org/~esr/jargon/html/entry/DWIM.html
Ralph.
^ permalink raw reply [flat|nested] 103+ messages in thread
* [9fans] blanks in file names
@ 2002-07-02 9:53 Fco.J.Ballesteros
0 siblings, 0 replies; 103+ messages in thread
From: Fco.J.Ballesteros @ 2002-07-02 9:53 UTC (permalink / raw)
To: 9fans
After reading all the post about this, and thinking about it
I think it's more clean to use different characters for space and
blank within a file name — as someone said before.
The reason why I think so is that it would simplify the library
and at the same time avoid problems with quoting. For example,
although replica uses %q, I ended up deleting a file name 'chk, because
somehow replica got confussed. It's true that I could have tried
to avoid the confussion and fix the bug; but I think this suggests that
it's not so easy to quote things.
On the other side, there're two places where file names get blanks in:
- from foreign systems
- locally created files
On both places it'd be easy for the user to type Alt-spc, perhaps more
simpler than it'd be to write 'blah blah'.
Now, does anyone from the Labs think otherwise, and if so,
what's the reason. I'd like to learn from this mistake, if my current
view of the problem can be considered as so.
In any case, I agree that blanks are here to stay and I'd like Plan 9
to handle then as nicely as it handles ☺ⁱ.
thanks
ⁱ Why did ☺ get into unicode?
Why didn't :-( get in then? (Did they read TPOP?).
^ permalink raw reply [flat|nested] 103+ messages in thread
end of thread, other threads:[~2002-07-21 19:52 UTC | newest]
Thread overview: 103+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-07-08 20:22 [9fans] blanks in file names rob pike, esq.
2002-07-08 21:21 ` Dave
2002-07-08 23:27 ` Dan Cross
2002-07-08 23:30 ` Dan Cross
-- strict thread matches above, loose matches on Subject: below --
2002-07-15 4:03 Geoff Collyer
2002-07-15 14:53 ` Jack Johnson
2002-07-21 19:52 ` Dave
2002-07-21 19:47 ` Dave
2002-07-14 18:28 rob pike, esq.
2002-07-11 23:56 okamoto
2002-07-11 8:39 Geoff Collyer
2002-07-14 18:13 ` Dave
2002-07-11 5:50 okamoto
2002-07-11 1:41 anothy
[not found] ` <"anothy@cosym.net"@Jul>
2002-07-11 6:47 ` Dave
2002-07-10 18:27 David Gordon Hogan
2002-07-10 20:56 ` arisawa
2002-07-10 8:00 Fco.J.Ballesteros
2002-07-09 7:54 Fco.J.Ballesteros
2002-07-09 1:08 okamoto
2002-07-08 23:19 David Gordon Hogan
2002-07-08 23:30 ` Dave
2002-07-08 12:18 forsyth
[not found] ` <"forsyth@caldo.demon.co.uk"@Jul>
2002-07-08 20:42 ` Dave
2002-07-08 8:59 Fco.J.Ballesteros
[not found] ` <Fco.J.Ballesteros@Jul>
2002-07-08 20:18 ` Dave
2002-07-09 15:23 ` Dave
2002-07-10 16:02 ` Dave
2002-07-10 20:59 ` FJ Ballesteros
2002-07-10 21:51 ` Dave
2002-07-10 22:22 ` Dan Cross
2002-07-10 23:01 ` Dave
2002-07-11 2:00 ` Dan Cross
2002-07-11 6:14 ` Dave
2002-07-11 6:38 ` Lucio De Re
2002-07-14 18:00 ` Dave
2002-07-11 13:14 ` arisawa
2002-07-12 12:28 ` arisawa
2002-07-11 16:23 ` Dan Cross
2002-07-11 10:43 ` Ish Rattan
2002-07-14 18:49 ` Dave
2002-07-08 0:38 Scott Schwartz
2002-07-07 5:59 Geoff Collyer
2002-07-05 19:21 David Gordon Hogan
2002-07-05 19:52 ` Jim Choate
2002-07-05 20:10 ` Mark Bitting
2002-07-05 18:26 Sape Mullender
2002-07-05 18:23 David Gordon Hogan
2002-07-05 1:21 okamoto
[not found] <20020703160003.27491.58783.Mailman@psuvax1.cse.psu.edu>
2002-07-04 23:35 ` Andrew Simmons
2002-07-04 22:42 ` Sam
2002-07-04 22:44 ` Sam
2002-07-08 16:14 ` ozan s yigit
2002-07-04 12:26 Fco.J.Ballesteros
2002-07-04 12:20 forsyth
2002-07-04 11:37 Fco.J.Ballesteros
2002-07-04 11:36 rog
2002-07-04 9:50 Fco.J.Ballesteros
2002-07-04 9:41 forsyth
2002-07-04 8:31 Fco.J.Ballesteros
2002-07-04 8:22 forsyth
2002-07-04 7:53 Fco.J.Ballesteros
2002-07-04 7:47 Fco.J.Ballesteros
2002-07-04 6:34 forsyth
2002-07-04 7:39 ` Lucio De Re
2002-07-04 9:32 ` Nikolai SAOUKH
2002-07-03 8:00 Fco.J.Ballesteros
2002-07-03 12:00 ` Lucio De Re
2002-07-03 19:39 ` rob pike, esq.
2002-07-07 4:02 ` Dave
2002-07-07 5:17 ` arisawa
[not found] ` <"arisawa@ar.aichi-u.ac.jp"@Jul>
2002-07-07 5:38 ` Dave
2002-07-07 6:04 ` arisawa
2002-07-07 7:16 ` arisawa
2002-07-07 16:11 ` Dave
2002-07-07 16:12 ` Dave
2002-07-10 21:58 ` Dave
2002-07-10 22:38 ` arisawa
2002-07-11 5:10 ` Dave
2002-07-14 18:32 ` Dave
2002-07-14 18:51 ` Jim Choate
2002-07-14 23:27 ` arisawa
2002-07-08 9:48 ` Boyd Roberts
2002-07-08 20:22 ` Dave
2002-07-09 8:24 ` Boyd Roberts
2002-07-09 15:25 ` Dave
2002-07-08 23:05 ` Berry Kercheval
2002-07-02 18:14 rog
2002-07-02 23:08 ` Dan Cross
2002-07-02 11:09 forsyth
2002-07-02 11:53 ` matt
2002-07-02 13:29 ` Boyd Roberts
2002-07-02 14:57 ` FJ Ballesteros
2002-07-02 16:23 ` Lucio De Re
2002-07-03 19:21 ` rob pike, esq.
2002-07-03 14:31 ` FJ Ballesteros
2002-07-02 18:28 ` plan9
2002-07-03 13:54 ` arisawa
2002-07-03 14:24 ` FJ Ballesteros
2002-07-03 19:40 ` rob pike, esq.
2002-07-03 22:10 ` arisawa
2002-07-04 8:30 ` Ralph Corderoy
2002-07-02 9:53 Fco.J.Ballesteros
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).