Re: [PATCH v3 3/7] builtin/refs: add verify subcommand
shejialuo <shejialuo@gmail.com> writes:
Show 43 quoted lines
> Introduce a new subcommand "verify" in git-refs(1) to allow the user to
> check the reference database consistency.
>
> Mentored-by: Patrick Steinhardt <ps@pks.im>
> Mentored-by: Karthik Nayak <karthik.188@gmail.com>
> Signed-off-by: shejialuo <shejialuo@gmail.com>
> ---
> Documentation/git-refs.txt | 13 +++++++++++
> builtin/refs.c | 45 ++++++++++++++++++++++++++++++++++++++
> 2 files changed, 58 insertions(+)
>
> diff --git a/Documentation/git-refs.txt b/Documentation/git-refs.txt
> index 5b99e04385..16b518ecce 100644
> --- a/Documentation/git-refs.txt
> +++ b/Documentation/git-refs.txt
> @@ -10,6 +10,7 @@ SYNOPSIS
> --------
> [verse]
> 'git refs migrate' --ref-format=<format> [--dry-run]
> +'git refs verify' [--strict] [--verbose]
>
> DESCRIPTION
> -----------
> @@ -22,6 +23,9 @@ COMMANDS
> migrate::
> Migrate ref store between different formats.
>
> +verify::
> + Verify reference database consistency.
> +
> OPTIONS
> -------
>
> @@ -39,6 +43,15 @@ include::ref-storage-format.txt[]
> can be used to double check that the migration works as expected before
> performing the actual migration.
>
> +The following options are specific to 'git refs verify':
> +
> +--strict::
> + Enable more strict checking, every WARN severity for the `Fsck Messages`
> + be seen as ERROR.
> +
Nit: It would be nice to redirect users to the fsck documentation to
understand severity levels.
[snip]