Skip to content
Fetching contributors…
Cannot retrieve contributors at this time
15 lines (13 sloc) 410 Bytes
-- | jspcat - print the contents of a JSMod intermediate file.
module Main where
import System.Environment (getArgs)
import CodeGen.Javascript
import CodeGen.Javascript.AST (bogusJSVar)
main = do
as <- getArgs
if null as
then putStrLn "Usage: jspcat Mod1.jsmod [Mod2.jsmod, ...]"
else mapM_ catMod as
where
catMod m =
readModule "." m >>= putStrLn . fst . prettyJS pseudo bogusJSVar
Something went wrong with that request. Please try again.