1 import LibDirectory (getCurrentDirectory, setCurrentDirectory,
2 createDirectory, removeDirectory, getDirectoryContents)
5 getCurrentDirectory >>= \ oldpwd ->
6 createDirectory "foo" >>
7 setCurrentDirectory "foo" >>
8 getDirectoryContents "." >>= \ [n1, n2] ->
9 if dot n1 && dot n2 then
10 setCurrentDirectory oldpwd >>
11 removeDirectory "foo" >>