Creates a temporary file with content that will auto delete as soon as there is no longer any references to it.

tmpfile(content=NULL, ...)

Arguments

content

A character string to be written to the file.

...

Optional arguments passed to tempfile().

Value

The absolute pathname to the temporary file.

Author

Henrik Bengtsson

See also

Examples

  md5 <- tools::md5sum(tmpfile("Hello world!"))
  print(md5)
#> /tmp/henrik/RtmpAr1qq8/file23139619ecb0d 
#>       "86fb269d190d2c85f6e0468ceca42a20"