better readProcess

This commit is contained in:
Joey Hess 2012-07-19 00:57:40 -04:00
parent 1db7d27a45
commit 9fc94d780b
6 changed files with 21 additions and 9 deletions

View file

@ -32,7 +32,7 @@ configkey = annexConfig "uuid"
{- Generates a UUID. There is a library for this, but it's not packaged,
- so use the command line tool. -}
genUUID :: IO UUID
genUUID = gen . lines <$> readProcess command params []
genUUID = gen . lines <$> readProcess command params
where
gen [] = error $ "no output from " ++ command
gen (l:_) = toUUID l