[QUESTION] mergetool environment variables

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

 



I am trying to integrate a custom mergetool with a shell wrapper.
What I get from the online help is the following description referring
to the command and environment variables.

mergetool.<tool>.cmd 
Specify the command to invoke the specified merge tool.
The specified command is evaluated in shell with the
following variables available: BASE is the name of a
temporary file containing the common base of the files
to be merged, if available; LOCAL is the name of a
temporary file containing the contents of the file on
the current branch; REMOTE is the name of a temporary
file containing the contents of the file from the branch
being merged; MERGED contains the name of the file
to which the merge tool should write the results of a
successful merge.

When I try to use this from a shell, simply with:
#!/bin/sh
env
exit 1

the described environment variables: BASE, LOCAL,
REMOTE, and MERGED, are not present.

The history is trivial, but has a 1 line conflict after a
git merge. The file is called a, with two lines at the
parent commit and the middle line changed in both
branches being merged. There are correct temp files
in the directory while the shell script is being run. The
merged file looks as follows:

Hello
<<<<<<< HEAD
Ours
=======
Theirs
>>>>>>> Incoming
World

This applies to git 2.45.1 in cygwin and 2.51.0 on NonStop.
There are no upstreams. Is this the problem?

Any thoughts on this?

Thanks,
Randall

--
Brief whoami: NonStop&UNIX developer since approximately
UNIX(421664400)
NonStop(211288444200000000)
-- In real life, I talk too much.






[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