summaryrefslogtreecommitdiff
path: root/Git/LsFiles.hs
diff options
context:
space:
mode:
authorGravatar Joey Hess <joey@kitenet.net>2013-03-07 19:03:06 -0400
committerGravatar Joey Hess <joey@kitenet.net>2013-03-07 19:03:06 -0400
commitc25b0262ea2a7322f8d2ef8aa12db05c5e5e2d1f (patch)
tree64d07d30cc3c0a87f5ed73a6a91037a40b6fce19 /Git/LsFiles.hs
parent1dad90c42c6f020a619daa365189adf8d6731ae5 (diff)
Bugfix: git annex add, when ran without any file or directory specified, should add files in the current directory, but not act on unlocked files elsewhere in the tree.
Diffstat (limited to 'Git/LsFiles.hs')
-rw-r--r--Git/LsFiles.hs2
1 files changed, 1 insertions, 1 deletions
diff --git a/Git/LsFiles.hs b/Git/LsFiles.hs
index ca08fe261..82ce0edaf 100644
--- a/Git/LsFiles.hs
+++ b/Git/LsFiles.hs
@@ -105,7 +105,7 @@ typeChanged' ps l repo = do
return (map (\f -> relPathDirToFile cwd $ top </> f) fs, cleanup)
where
prefix = [Params "diff --name-only --diff-filter=T -z"]
- suffix = Param "--" : map File l
+ suffix = Param "--" : (if null l then [File "."] else map File l)
{- A item in conflict has two possible values.
- Either can be Nothing, when that side deleted the file. -}