From: jmadam (John M. Adams)

Subject: Re: make-pathname

Date: 2003-1-21 11:42

Use :device "D:\\" in your make-pathname call.  The pathname
facilities won't work as expected if you treat the drive specifier as
a directory name prefix.

Jorge Tavares <dei.uc.pt at jast> writes:

> Hi, > > This is a simple question but until now I was unable to find an > answer. Supose i want to make a function that writes into a file in a > specified directory. > > > For example: > > (defun make-index () > (with-open-file (str (make-pathname > :name "index.html" :directory '(:absolute > "webpage")) > > :direction :output :if-exists :supersede > :if-does-not-exist :create) > (html-stream str (:html > (:head (:title "Test")) > (:body (:h1 "Test") > "HTML generator test."))))) > > In this function, I can do what I want but with the exception of one > minor detail: it saves the "index.html" in "C:\webpage". If I want the > drive changed, for example "D:\webpage", what is the :absolute > replacement? I've tried just puttng the string "D:\\webpage" but it > always translate into "C:\<ACL DIR>\D:\webpage". > > > What are the options for make-pathname? I've search the documentation > but I was unable to find something this simple. > > > > Thanks in advance for any kind of advice, > Jorge Tavares > > -- > Jorge Tavares > http://www.dei.uc.pt/~jast > > "Evolution is the best engineer." > > >
-- John Michael Adams