i think, you should better call  ```File.deleteOnExit```after creating temporary file.