next | previous | forward | backward | up | top | index | toc | Macaulay2 web site
Macaulay2Doc > The Macaulay2 language > file manipulation > temporaryFileName

temporaryFileName -- make a temporary file name

Synopsis

Description

The file name is so unique that even with various suffixes appended, no collision with existing files should occur. But no check is done to see whether such files are present.
i1 : temporaryFileName () | ".tex"

o1 = /tmp/M2-50919-1.tex
i2 : temporaryFileName () | ".html"

o2 = /tmp/M2-50919-2.html

This function will work under Unix, and also under Windows if you have a directory on the same drive called /tmp.

If the name of the temporary file will be given to an external program, it may be necessary to concatenate it with rootPath or rootURI to enable the external program to find the file.

See also