[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

logical pathnames



I'm trying to use logical pathnames and running into problems when I want
to define one logical pathname in terms of previously defined ones.
For example, I start with:

(setf (logical-pathname-translations "MCL")
      `((,(make-pathname :host "MCL"
                         :directory nil
                         :name nil
                         :type nil)
         ,(make-pathname :directory (mac-namestring "ccl;")
                         :name nil
                         :type nil))))

Now I want another logical-pathname to foo which is in MCL.

(setf (logical-pathname-translations "oou")
      `((,(make-pathname :host "oou"
                         :directory nil
                         :name nil
                         :type nil)
        ,(make-pathname :directory ???mystery-form
                        :name nil
                        :type nil))))

I've found that ???mystery-form has to be:

  (namestring (translate-logical-pathname "MCL:foo"))

Which seems pretty ugly

  (mac-namestring "MCL:oodles-of-utils")

works too but obviously isn't a portable technique.

I can think of a few other things that would work,
but nothing elegant.

-ME