move mktemp method into homebrew-fork resource.rb

This is the only place it is used.
No longer need to `include FileUtils`.