module Main where

import           Data.NML.XMLLight
import qualified Data.Text.IO as T
import           Text.XML.Light.Output (showContent)

main :: IO ()
main = do
  contents <- T.getContents
  let xml = decode contents
  case xml of
    Just x  -> putStrLn (showContent x)
    Nothing -> error "Unable to parse NML document"
