Skip to main content.
home | support | download

Back to List Archive

Re: FileFilter '%p' does not give FULL path to

From: Bill Moseley <moseley(at)not-real.hank.org>
Date: Thu Oct 10 2002 - 10:28:46 GMT
At 04:47 PM 10/09/02 -0700, Greg Fenton wrote:
>> Is the problem you need the "real" path or that the (temporary) path
>> name provided is not complete?
>> 
>
>
>I need the full path to the temporary file.
>'%p' gives "./as8f4y75"

That is the path to the temporary file (although that's doesn't look like a
temporary file generated by swish).

For example, if I use -S prog with a filter I get two arguments passed by
default to the filter.

  FileFilter .html ./filter.pl

"filter.pl" simply prints out @ARGV:

  './swtmpfltrnPrBDd'
  'http://localhost/index.html'

Now, if you mean you want an absolute path from root set the location of
the temporary file to an absolute path:

> export TEMP=/tmp

'/tmp/swtmpfltrH0fva4'
'http://localhost/index.html'

>'%f' gives "as8f4y75"
>'%d' gives "./"   (not very useful in my opinion).

It's useful if your filter needs to know just the directory name.  Not sure
why a filter might need that, but it's there just in case.


-- 
Bill Moseley
mailto:moseley@hank.org
Received on Thu Oct 10 10:32:30 2002