Re: [PATCH 1/2] format-patch: fix dashdash usage

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

 



On Thu, Nov 26, 2009 at 9:57 PM, Junio C Hamano <gitster@xxxxxxxxx> wrote:
> Felipe Contreras <felipe.contreras@xxxxxxxxx> writes:
>
>> Otherwise 'git format-patch <committish> -- <non-existent-path>' doesn't
>> work.
>
> Instead of "doesn't work", I really wished you wrote something like:
>
>    $ git format-patch <commit> -- <path>
>
>    complains that <path> does not exist in the current work tree and the
>    user needs to explicitly specify "--", even though the user _did_ give
>    a "--".  This is because it incorrectly removes "--" from the command
>    line arguments that is later passed to setup_revisions().

Complaining is one thing... failing to do anything is another.

> Remember that you are trying to help somebody who has to write Release
> Notes out of "git log" output.
>
> I actually have a bigger question, though.  Does it even make sense to
> allow pathspecs to format-patch?  We sure are currently loose and take
> them, but I doubt it is by design.

Not everyone has clean branches only with pertinent patches.

I stumbled upon this trying to re-create (cleanly) a "branch" that was
constantly merged into another "master" branch that had a lot more
stuff. Maybe there was a smarter way to do that with 'git rebase', but
that doesn't mean format-patch -- <path> shouldn't work.

> The patch itself looks good and is a candidate 'maint' material, if the
> answer to the above question is a convincing "yes, because ...".

Yeah, I also think this should go into 'maint'.

-- 
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]