merge: Support --json and --json-error-messages and --json-progress

Seems unlikely to be very useful, but trivial.
And, this completes the story that git-annex sync does not need json,
since every sub-operation is available in a command that does support json.
(Well, except for committing, but that's not a git-annex command.)

Sponsored-By: the NIH-funded NICEMAN (ReproNim TR&D3) project
This commit is contained in:
Joey Hess 2023-05-10 12:32:00 -04:00
parent daaf7e10be
commit c98fb0b637
No known key found for this signature in database
GPG key ID: DB12DB0FF05F8F38
4 changed files with 17 additions and 8 deletions

View file

@ -16,9 +16,10 @@ import Command.Sync (prepMerge, mergeLocal, mergeConfig, merge, notOnlyAnnexOpti
import Git.Types
cmd :: Command
cmd = command "merge" SectionMaintenance
"merge changes from remotes"
(paramOptional paramRef) (seek <$$> optParser)
cmd = withAnnexOptions [jsonOptions] $
command "merge" SectionMaintenance
"merge changes from remotes"
(paramOptional paramRef) (seek <$$> optParser)
data MergeOptions = MergeOptions
{ mergeBranches :: [String]