Re: [PATCH v3/RFC] Remove the use of '--' in merge program invocation

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

 



Patrick Higgins <patrick.higgins@xxxxxxxx> writes:

> Put a "./" at the beginning of all paths given to the merge program so
> that filenames beginning with a '-' character don't get interpreted as
> options.
>
> This deals with a problem where kdiff3 can be compiled with or without
> support for the '--' separator between options and filenames.
>
> Signed-off-by: Patrick Higgins <patrick.higgins@xxxxxxxx>
> ---
>
> This is applying Junio's idea because my earlier attempts would fail on files
> that started with a dash. This should work for those files with kdiff3
> compiled with or without '--' support, does not require any additional
> overhead to determine if kdiff3 has that support, and the technique should
> work for all merge programs in case any others have the problem kdiff3 has.
>
> My only concern is if 'git ls-files -u' ever returns absolute paths,
> then this will not work.

What do you mean by "absolute paths"?  The path git proper deals with is
always relative to the root of the repository's work tree, so you won't be
seeing "/home/patrick/src/Makefile" from ls-files if that is what you are
worried about.

This change applies to all the backends not just kdiff3; people who use
different merge backends please give success (or breakage) reports.

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

  Powered by Linux