Re: [PATCH v2 3/8] cherry-pick: add --skip-empty option

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Jun 4, 2013 at 1:30 PM, Junio C Hamano <gitster@xxxxxxxxx> wrote:
> Felipe Contreras <felipe.contreras@xxxxxxxxx> writes:
>
>> You didn't answer, what happens when you run --skip-empty and --allow-empty?
>
> I'll answer to a slightly different question: What should happen?
>
> I think it should error out, because --allow-empty is about
> "allowing empty commits to be preserved", and --skip-empty is about
> "skipping empty commits (as it says on the package)".

Exactly, so they are related after all. However, --allow-empty says this:

"By default, cherry-picking an empty commit will fail,"

Should we change that too if we introduce --skip-empty?

I don't think so. I think it makes more sense to have a new
--empty-commits=[keep|skip|fail] option, so we don't have to document
how each option affects the other, and what is the default. Or rather;
the option documents that.

In fact, it might make sense to change the default in v2.0 to
--empty-commits=skip. If it makes sense in 'git rebase', why doesn't
it in 'git cherry-pick'?

-- 
Felipe Contreras
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]