Bugfix to git annex unused in a repository with nothing yet annexed.
This commit is contained in:
parent
ea70873b11
commit
c4a357d5d1
3 changed files with 15 additions and 3 deletions
10
Core.hs
10
Core.hs
|
@ -185,9 +185,13 @@ getKeysPresent = do
|
|||
getKeysPresent' $ annexObjectDir g
|
||||
getKeysPresent' :: FilePath -> Annex [Key]
|
||||
getKeysPresent' dir = do
|
||||
contents <- liftIO $ getDirectoryContents dir
|
||||
files <- liftIO $ filterM present contents
|
||||
return $ map fileKey files
|
||||
exists <- liftIO $ doesDirectoryExist dir
|
||||
if (not exists)
|
||||
then return []
|
||||
else do
|
||||
contents <- liftIO $ getDirectoryContents dir
|
||||
files <- liftIO $ filterM present contents
|
||||
return $ map fileKey files
|
||||
where
|
||||
present d = do
|
||||
result <- try $
|
||||
|
|
6
debian/changelog
vendored
6
debian/changelog
vendored
|
@ -1,3 +1,9 @@
|
|||
git-annex (0.14) UNRELEASED; urgency=low
|
||||
|
||||
* Bugfix to git annex unused in a repository with nothing yet annexed.
|
||||
|
||||
-- Joey Hess <joeyh@debian.org> Mon, 20 Dec 2010 14:54:49 -0400
|
||||
|
||||
git-annex (0.13) unstable; urgency=low
|
||||
|
||||
* Makefile: Install man page and html (when built).
|
||||
|
|
|
@ -11,3 +11,5 @@ The ``git annex unused`` command fails on a git-annex repository, if there are n
|
|||
This can give a user (especially one that wants to try out simple commands with his newly created repo) the impression that something is wrong, while it is not. I'd expect the program either to show the same message ``git annex unused`` shows when everything is ok (since it is, or should be).
|
||||
|
||||
This can be a bug in the ``unused`` subcommand (that fails to accept the absence of an objects directory) or in the ``init`` subcommand (that fails to create it).
|
||||
|
||||
> [[fixed|done]] --[[Joey]]
|
||||
|
|
Loading…
Reference in a new issue