Created
April 27, 2014 08:03
-
-
Save dacr/11340168 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def res2file(from: String, dest: File) { | |
import scalax.io._ | |
val in = Resource.fromInputStream(getClass().getClassLoader.getResourceAsStream(from)) | |
val output: Output = Resource.fromFile(dest) | |
output.write(in.bytes) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment