Subject: Re: [PATCH v6 1/9] pack-objects: use standard option incompatibility functions

From: Taylor Blau <[email-masked]>
Date: Tue, 24 Jun 2025 12:06:51 -0400

On Tue, Jun 24, 2025 at 08:52:59AM -0700, Junio C Hamano wrote:
> Taylor Blau <[email-masked]> writes:
>
> > @@ -5050,13 +5051,14 @@ int cmd_pack_objects(int argc,
> >  	if (!pack_to_stdout && thin)
> >  		die(_("--thin cannot be used to build an indexable pack"));
> >
> > -	if (keep_unreachable && unpack_unreachable)
> > -		die(_("options '%s' and '%s' cannot be used together"), "--keep-unreachable", "--unpack-unreachable");
> > +	die_for_incompatible_opt2(keep_unreachable, "--keep-unreachable",
> > +				  unpack_unreachable, "--unpack-unreachable");
> >  	if (!rev_list_all || !rev_list_reflog || !rev_list_index)
> >  		unpack_unreachable_expiration = 0;
> >
> > -	if (stdin_packs && filter_options.choice)
> > -		die(_("cannot use --filter with --stdin-packs"));
> > +	die_for_incompatible_opt2(stdin_packs, "--stdin-packs",
> > +				  filter_options.choice, "--filter");
> > +
> >
>
> We do not need two blank lines here, do we?

Yeah, it looks like an extra one snuck in and I missed it when
proof-reading.

Thanks,
Taylor