diff options
-rw-r--r-- | Utility/DataUnits.hs | 8 | ||||
-rw-r--r-- | doc/special_remotes/directory/comment_12._comment | 16 |
2 files changed, 20 insertions, 4 deletions
diff --git a/Utility/DataUnits.hs b/Utility/DataUnits.hs index e5c2fc83e..511b3be80 100644 --- a/Utility/DataUnits.hs +++ b/Utility/DataUnits.hs @@ -118,7 +118,7 @@ roughSize units abbrev i showUnit i' (Unit s a n) = let (num, decimal) = chop i' s in show num ++ decimal ++ " " ++ - (if abbrev then a else plural num n) + (if abbrev then a else plural num decimal n) chop :: Integer -> Integer -> (Integer, String) chop i' d = @@ -130,9 +130,9 @@ roughSize units abbrev i then (num, "") else (num, "." ++ ds') - plural n u - | n == 1 = u - | otherwise = u ++ "s" + plural num decimal n + | num == 1 && null decimal = n + | otherwise = n ++ "s" {- displays comparison of two sizes -} compareSizes :: [Unit] -> Bool -> ByteSize -> ByteSize -> String diff --git a/doc/special_remotes/directory/comment_12._comment b/doc/special_remotes/directory/comment_12._comment new file mode 100644 index 000000000..608fb62cd --- /dev/null +++ b/doc/special_remotes/directory/comment_12._comment @@ -0,0 +1,16 @@ +[[!comment format=mdwn + username="http://joeyh.name/" + ip="4.153.2.25" + subject="comment 2" + date="2013-07-19T13:54:10Z" + content=""" +@Laura the directory special remote requires files to +be in a particular directory structure with special names +git-annex comes up with. So you can't use it on an existing +tree of files like that. + +What you can do is use the [[web_special_remote|web]], +with a `file://` url to point to the files wherever +they are stored. So for example, +`git annex addurl file:///media/dvd/file` +"""]] |