unused, dropunused: Now work in bare repositories.
Turned out I had already done all the work needed to support this when unused started checking all branches.
This commit is contained in:
parent
c102e63595
commit
22e9f445ab
5 changed files with 13 additions and 14 deletions
|
@ -35,7 +35,7 @@ withUnusedMaps params = do
|
|||
return $ map (start (unused, unusedbad, unusedtmp)) params
|
||||
|
||||
start :: (UnusedMap, UnusedMap, UnusedMap) -> FilePath -> CommandStart
|
||||
start (unused, unusedbad, unusedtmp) s = notBareRepo $ search
|
||||
start (unused, unusedbad, unusedtmp) s = search
|
||||
[ (unused, perform)
|
||||
, (unusedbad, performOther gitAnnexBadLocation)
|
||||
, (unusedtmp, performOther gitAnnexTmpLocation)
|
||||
|
|
|
@ -36,7 +36,7 @@ seek = [withNothing start]
|
|||
|
||||
{- Finds unused content in the annex. -}
|
||||
start :: CommandStart
|
||||
start = notBareRepo $ do
|
||||
start = do
|
||||
from <- Annex.getState Annex.fromremote
|
||||
let (name, action) = case from of
|
||||
Nothing -> (".", checkUnused)
|
||||
|
|
1
debian/changelog
vendored
1
debian/changelog
vendored
|
@ -12,6 +12,7 @@ git-annex (3.20111026) UNRELEASED; urgency=low
|
|||
and file contents. Does not check that numcopies is satisfied, as
|
||||
.gitattributes information about numcopies is not available in a bare
|
||||
repository.
|
||||
* unused, dropunused: Now work in bare repositories.
|
||||
|
||||
-- Joey Hess <joeyh@debian.org> Thu, 27 Oct 2011 13:58:53 -0400
|
||||
|
||||
|
|
|
@ -7,16 +7,12 @@ Of course, for that to work, the bare repository has to be on a system with
|
|||
[[git-annex-shell]] installed. If "origin" is on GitWeb, you still can't
|
||||
use git-annex to store stuff there.
|
||||
|
||||
Known to work ok:
|
||||
It took a while, but bare repositories are now supported exactly as well
|
||||
as non-bare repositories. Except for these caveats:
|
||||
|
||||
* `git annex move --to` and `--from`, when pointed at a bare repository.
|
||||
* `git annex copy` ditto.
|
||||
* `git annex drop` can check that a bare repository has a copy of data
|
||||
that is being dropped.
|
||||
* `git annex get` can transfer data from a bare repository.
|
||||
* Most other stuff (ie, init, describe, trust, etc.)
|
||||
|
||||
There are a few caveats to keep in mind when using bare repositories:
|
||||
|
||||
* A few subcommands, like `unused` cannot be run in a bare repository.
|
||||
Those subcommands will refuse to do anything.
|
||||
* `git annex fsck` works in a bare repository, but does not display
|
||||
warnings about insufficient
|
||||
[[copies]]. To get those warnings, just run it in one of the non-bare
|
||||
checkouts.
|
||||
* `git annex unused` in a bare repository only knows about keys used in
|
||||
branches that have been pushed to the bare repository. So use it with care..
|
||||
|
|
|
@ -12,4 +12,6 @@ What is says on the tin:
|
|||
|
||||
>> Fsck is done. Rest not done yet. --[[Joey]]
|
||||
|
||||
>>> all [[done]]! --[[Joey]]
|
||||
|
||||
[[!meta title="support unused, dropunused in bare repos"]]
|
||||
|
|
Loading…
Reference in a new issue