From fa5c016585b61e84c9ef7e7f6e6814693599a66a Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Tue, 11 Oct 2011 23:49:58 -0400 Subject: add comment about relative/absolute filenames --- Git.hs | 3 +++ 1 file changed, 3 insertions(+) (limited to 'Git.hs') diff --git a/Git.hs b/Git.hs index fb998b1b0..044fc08ae 100644 --- a/Git.hs +++ b/Git.hs @@ -547,6 +547,9 @@ configMap = config {- Efficiently looks up a gitattributes value for each file in a list. -} checkAttr :: Repo -> String -> [FilePath] -> IO [(FilePath, String)] checkAttr repo attr files = do + -- git check-attr needs relative filenames input; it will choke + -- on some absolute filenames. This also means it will output + -- all relative filenames. cwd <- getCurrentDirectory let relfiles = map (relPathDirToFile cwd . absPathFrom cwd) files (_, fromh, toh) <- hPipeBoth "git" (toCommand params) -- cgit v1.2.3