generate files from stringtemplates and json variables in haskell