From 94554782894ec6c26da3b46312d5d1d16d596458 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Thu, 13 Dec 2012 00:24:19 -0400 Subject: finished where indentation changes --- Git/CheckAttr.hs | 58 ++++++++++++++++++++++++++++---------------------------- 1 file changed, 29 insertions(+), 29 deletions(-) (limited to 'Git/CheckAttr.hs') diff --git a/Git/CheckAttr.hs b/Git/CheckAttr.hs index 13a7287b1..f9279d460 100644 --- a/Git/CheckAttr.hs +++ b/Git/CheckAttr.hs @@ -24,12 +24,12 @@ checkAttrStart attrs repo = do cwd <- getCurrentDirectory h <- gitCoProcessStart params repo return (h, attrs, cwd) - where - params = - [ Param "check-attr" - , Params "-z --stdin" - ] ++ map Param attrs ++ - [ Param "--" ] + where + params = + [ Param "check-attr" + , Params "-z --stdin" + ] ++ map Param attrs ++ + [ Param "--" ] checkAttrStop :: CheckAttrHandle -> IO () checkAttrStop (h, _, _) = CoProcess.stop h @@ -42,26 +42,26 @@ checkAttr (h, attrs, cwd) want file = do case vals of [v] -> return v _ -> error $ "unable to determine " ++ want ++ " attribute of " ++ file - where - send to = do - fileEncoding to - hPutStr to $ file' ++ "\0" - receive from = forM attrs $ \attr -> do - fileEncoding from - l <- hGetLine from - return (attr, attrvalue attr l) - {- Before git 1.7.7, git check-attr worked best with - - absolute filenames; using them worked around some bugs - - with relative filenames. - - - - With newer git, git check-attr chokes on some absolute - - filenames, and the bugs that necessitated them were fixed, - - so use relative filenames. -} - oldgit = Git.Version.older "1.7.7" - file' - | oldgit = absPathFrom cwd file - | otherwise = relPathDirToFile cwd $ absPathFrom cwd file - attrvalue attr l = end bits !! 0 - where - bits = split sep l - sep = ": " ++ attr ++ ": " + where + send to = do + fileEncoding to + hPutStr to $ file' ++ "\0" + receive from = forM attrs $ \attr -> do + fileEncoding from + l <- hGetLine from + return (attr, attrvalue attr l) + {- Before git 1.7.7, git check-attr worked best with + - absolute filenames; using them worked around some bugs + - with relative filenames. + - + - With newer git, git check-attr chokes on some absolute + - filenames, and the bugs that necessitated them were fixed, + - so use relative filenames. -} + oldgit = Git.Version.older "1.7.7" + file' + | oldgit = absPathFrom cwd file + | otherwise = relPathDirToFile cwd $ absPathFrom cwd file + attrvalue attr l = end bits !! 0 + where + bits = split sep l + sep = ": " ++ attr ++ ": " -- cgit v1.2.3