summaryrefslogtreecommitdiff
path: root/Locations.hs
diff options
context:
space:
mode:
authorGravatar Joey Hess <joey@kitenet.net>2012-05-31 21:03:24 -0400
committerGravatar Joey Hess <joey@kitenet.net>2012-05-31 21:03:24 -0400
commit6fd83851c13232b7810a33e8bb1d83e8a46bd354 (patch)
tree6144bcf207fd3867c54a4bcde35fe82bcc912c95 /Locations.hs
parentd4a95faeb2786027e13cc3f49825a6b4ad231768 (diff)
Fix display of warning message when encountering a file that uses an unsupported backend.
Diffstat (limited to 'Locations.hs')
-rw-r--r--Locations.hs4
1 files changed, 3 insertions, 1 deletions
diff --git a/Locations.hs b/Locations.hs
index 46a85e0ee..db456388a 100644
--- a/Locations.hs
+++ b/Locations.hs
@@ -155,7 +155,9 @@ gitAnnexRemotesDir r = addTrailingPathSeparator $ gitAnnexDir r </> "remotes"
{- Checks a symlink target to see if it appears to point to annexed content. -}
isLinkToAnnex :: FilePath -> Bool
-isLinkToAnnex s = ("/.git/" ++ objectDir) `isInfixOf` s
+isLinkToAnnex s = ("/" ++ d) `isInfixOf` s || d `isPrefixOf` s
+ where
+ d = ".git" </> objectDir
{- Converts a key into a filename fragment without any directory.
-