* (translate-logical-pathname "home:lisp;portableaserve;INSTALL.lisp")
#p"/home/sasha/lisp/portableaserve/install.lisp"
*
Is there any way to control a case conversion in this situation?
Or, may be, what is a proper way to use logical-pathnames with mixed-case
filenames under UNIX?
--
You need to understand that the point with logical pathnames is to have a
file-system--independent file naming convention that makes porting your
application to a different system not require any internal changes. This
is a fantastically useful thing. If Unix had had logical pathnames, Unix
administration, setup, package installation, etc, would have been simple
and straightforward. Instead, we have tons of different directories that
need to be kept in sync, and packages have compiled-in pathnames. After
I grokked logical pathnames, I have emulated or implemented them wherever
I have gone. Global file systems are simply not good at what they
attempt to do, and hardwiring directories into programs is simply wrong.
The mapping from logical to physical pathnames is strictly one-way. The
idea is to work within a known and safe universe of names and directories
that are always portably mappable to physical pathnames. As long as you
live within that universe, you have solved a number of problems that are
hard even to understand are solvable without such a (standard) mechanism.
So you construct the logical file system with a small number of logical
hosts and name all your files within it/them, and then arrange for the
physical world to have the physical files and directories to which they
are mapped. Going the other way around is simply misguided.
--
In a fight against something, the fight has value, victory has none.
In a fight for something, the fight is a loss, victory merely relief.
70 percent of American adults do not understand the scientific process.
Does this mean that I have to rename files on Unix systems to
make them accessible to logical pathnames? Right now I am working
on a small program for "overlaying" PDF files, and it would be
highly appreciated by the customer, if the generated file can
be found under the same name, case included.
Does anyone have data on how CL implementations on Windows behave
when they are accessing Unix files stored on a Samba server?
thanks,
s.
So, logical pathnames is a leverage for mapping pathnames for files that
are, in some sense, the part of a program, but it is not a leverage for
mapping to/from any phisical pathname into an internal representation.
Don't I misunderstand you?
If you are using logical pathnames, then yes, you may have to rename
files. Logical pathnames were not built to handle every pathname.
>
> Does anyone have data on how CL implementations on Windows behave
> when they are accessing Unix files stored on a Samba server?
A CL implementation would behave the same way any other Windows
program would behave.
Why are you using logical pathnames when you get input pathnames from the
user? What part of "one-way mapping" did you not understand? *sigh*
I have no idea how to answer this last question. Both "yes" and "no"
appear to mean that you misunderstand me. Consequently, I do not even
know whether you have stated something you believe or something you do
not believe.
The key is: You do _not_ map physical pathnames to logical.
Another bit fell into place ... thanks for the nudge.
s.