Pastebin launched a little side project called VERYVIRAL.com, check it out ;-) Want more features on Pastebin? Sign Up, it's FREE!
Guest

Untitled

By: a guest on Jul 10th, 2013  |  syntax: Haskell  |  size: 0.31 KB  |  views: 6  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. import System.Directory.Tree
  2. import qualified Data.Foldable as F
  3. import qualified Data.Traversable as T
  4.  
  5. main = do
  6.         dir <- readDirectoryWithL readFile "directory"
  7.         let
  8.                 tree = dirTree dir
  9.                 a:xs = contents tree
  10.         print $ name a
  11.         _ <- getLine -- manually change the content of the file here
  12.         print $ file a