Is it possible, and if yes how is it done? The usual >
and >>
that work on the Windows or Linux command line don't work in this context.
You can do it programmaticaly from console:
import java.io.FileOutputStream
import scala.Console
Console.setOut(new FileOutputStream("<output file path>"))
from now on all print
and println
would be directed into this file
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With