Skip to content

Instantly share code, notes, and snippets.

@seratch
Created October 22, 2012 10:39
Show Gist options
  • Save seratch/3930853 to your computer and use it in GitHub Desktop.
Save seratch/3930853 to your computer and use it in GitHub Desktop.
XML PrettyPrinter in Scala
import scala.xml._
val xml: Elem = XML.load("./input.xml")
val formatted: String = new PrettyPrinter(80, 2).format(xml)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment