Christian Stalp wrote: > Hello together, > I want to create a tempfile via the function tempfile. > But I want a certain path and name for the file. > The option DIR and SUFFIX and s.o. is clear to me but how can I > set the name of the file? For Exam: temp_file.lock or somethink like > that!?
The spirit of the module is to create a file that is for use by your process only and will not be used by any other processes. The file is typically removed when your process finishes. There must be some variable component to the filename so the module can find a file name that does not already exist. If you need to use a well-known file name (e.g. for a lock file to coordinate between processes), you should just use the standard open() or sysopen() functions. If you want to know what the OS considers the "temp" directory to be, you can use File::Spec->tmpdir() -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>