export: Deprecated the --tracking option.
Instead, users can configure remote.<name>.annex-tracking-branch themselves.
This commit is contained in:
parent
d805401708
commit
4747fa923d
5 changed files with 18 additions and 11 deletions
|
@ -58,7 +58,7 @@ optParser _ = ExportOptions
|
|||
)
|
||||
parsetracking = switch
|
||||
( long "tracking"
|
||||
<> help ("track changes to the " ++ paramTreeish)
|
||||
<> help ("track changes to the " ++ paramTreeish ++ " (deprecated)")
|
||||
)
|
||||
|
||||
-- To handle renames which swap files, the exported file is first renamed
|
||||
|
@ -73,7 +73,7 @@ seek o = do
|
|||
unlessM (isExportSupported r) $
|
||||
giveup "That remote does not support exports."
|
||||
when (exportTracking o) $
|
||||
setConfig (remoteConfig r "export-tracking")
|
||||
setConfig (remoteConfig r "annex-tracking-branch")
|
||||
(fromRef $ exportTreeish o)
|
||||
new <- fromMaybe (giveup "unknown tree") <$>
|
||||
-- Dereference the tree pointed to by the branch, commit,
|
||||
|
|
|
@ -680,8 +680,8 @@ syncFile ebloom rs af k = onlyActionOn' k $ do
|
|||
put dest = includeCommandAction $
|
||||
Command.Move.toStart' dest Command.Move.RemoveNever af k (mkActionItem af)
|
||||
|
||||
{- When a remote has an export-tracking branch, change the export to
|
||||
- follow the current content of the branch. Otherwise, transfer any files
|
||||
{- When a remote has an annex-tracking-branch configuration, change the export
|
||||
- to contain the current content of the branch. Otherwise, transfer any files
|
||||
- that were part of an export but are not in the remote yet.
|
||||
-
|
||||
- Returns True if any file transfers were made.
|
||||
|
@ -691,7 +691,7 @@ seekExportContent rs (currbranch, _) = or <$> forM rs go
|
|||
where
|
||||
go r = withExclusiveLock (gitAnnexExportLock (Remote.uuid r)) $ do
|
||||
db <- Export.openDb (Remote.uuid r)
|
||||
exported <- case remoteAnnexExportTracking (Remote.gitconfig r) of
|
||||
exported <- case remoteAnnexTrackingBranch (Remote.gitconfig r) of
|
||||
Nothing -> nontracking r
|
||||
Just b -> do
|
||||
mcur <- inRepo $ Git.Ref.tree b
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue