{"thread":{"id":"10195","subject":"[PATCH] mergetool: add support for ECMerge","startedAt":"2007-10-08T21:22:40Z","lastAt":"2007-10-09T14:21:27Z","messageCount":15,"participants":["Steffen Prohaska","Theodore Tso","Frank Lichtenheld","Johannes Schindelin","Alan Hadsell"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"55210","messageId":"11918785613855-git-send-email-prohaska@zib.de","threadId":"10195","inReplyTo":null,"subject":"[PATCH] mergetool: support absolute paths to tools by git config merge.<tool>path","fromName":"Steffen Prohaska","fromEmail":"prohaska@zib.de","sentAt":"2007-10-08T21:22:40Z","receivedAt":"2007-10-08T21:22:40Z","isPatch":true,"sender":{"key":"prohaska@zib.de","avatar":"https://avatars.githubusercontent.com/u/217580?v=4"},"body":"This commit adds a mechanism to provide absolute paths to the\ncommands called by 'git mergetool'. A path can be specified\nin the configuation variable merge.<toolname>path.\n\nThis mechanism is especially useful on Windows, where external\nprograms are unlikely to be in the path.\n\nSigned-off-by: Steffen Prohaska <prohaska@zib.de>\n---\n Documentation/git-mergetool.txt |    5 ++\n git-mergetool.sh                |   81 ++++++++++++++++++++++-----------------\n 2 files changed, 51 insertions(+), 35 deletions(-)\n\ndiff --git a/Documentation/git-mergetool.txt b/Documentation/git-mergetool.txt\nindex 6c32c6d..6b97aaa 100644\n--- a/Documentation/git-mergetool.txt\n+++ b/Documentation/git-mergetool.txt\n@@ -31,6 +31,11 @@ If a merge resolution program is not specified, 'git mergetool'\n will use the configuration variable merge.tool.  If the\n configuration variable merge.tool is not set, 'git mergetool'\n will pick a suitable default.\n++\n+You can explicitly provide a full path to the tool by setting the\n+configuration variable merge.<tool>path. For example, you\n+can configure the absolute path to kdiff3 by setting merge.kdiff3path.\n+Otherise, 'git mergetool' assumes the tool is available in PATH.\n \n Author\n ------\ndiff --git a/git-mergetool.sh b/git-mergetool.sh\nindex 9f4f313..7f6c16f 100755\n--- a/git-mergetool.sh\n+++ b/git-mergetool.sh\n@@ -192,10 +192,10 @@ merge_file () {\n     case \"$merge_tool\" in\n \tkdiff3)\n \t    if base_present ; then\n-\t\t(kdiff3 --auto --L1 \"$path (Base)\" --L2 \"$path (Local)\" --L3 \"$path (Remote)\" \\\n+\t\t(\"$merge_tool_path\" --auto --L1 \"$path (Base)\" --L2 \"$path (Local)\" --L3 \"$path (Remote)\" \\\n \t\t    -o \"$path\" -- \"$BASE\" \"$LOCAL\" \"$REMOTE\" > /dev/null 2>&1)\n \t    else\n-\t\t(kdiff3 --auto --L1 \"$path (Local)\" --L2 \"$path (Remote)\" \\\n+\t\t(\"$merge_tool_path\" --auto --L1 \"$path (Local)\" --L2 \"$path (Remote)\" \\\n \t\t    -o \"$path\" -- \"$LOCAL\" \"$REMOTE\" > /dev/null 2>&1)\n \t    fi\n \t    status=$?\n@@ -203,35 +203,35 @@ merge_file () {\n \t    ;;\n \ttkdiff)\n \t    if base_present ; then\n-\t\ttkdiff -a \"$BASE\" -o \"$path\" -- \"$LOCAL\" \"$REMOTE\"\n+\t\t\"$merge_tool_path\" -a \"$BASE\" -o \"$path\" -- \"$LOCAL\" \"$REMOTE\"\n \t    else\n-\t\ttkdiff -o \"$path\" -- \"$LOCAL\" \"$REMOTE\"\n+\t\t\"$merge_tool_path\" -o \"$path\" -- \"$LOCAL\" \"$REMOTE\"\n \t    fi\n \t    status=$?\n \t    save_backup\n \t    ;;\n \tmeld|vimdiff)\n \t    touch \"$BACKUP\"\n-\t    $merge_tool -- \"$LOCAL\" \"$path\" \"$REMOTE\"\n+\t    \"$merge_tool_path\" -- \"$LOCAL\" \"$path\" \"$REMOTE\"\n \t    check_unchanged\n \t    save_backup\n \t    ;;\n \tgvimdiff)\n \t\ttouch \"$BACKUP\"\n-\t\tgvimdiff -f -- \"$LOCAL\" \"$path\" \"$REMOTE\"\n+\t\t\"$merge_tool_path\" -f -- \"$LOCAL\" \"$path\" \"$REMOTE\"\n \t\tcheck_unchanged\n \t\tsave_backup\n \t\t;;\n \txxdiff)\n \t    touch \"$BACKUP\"\n \t    if base_present ; then\n-\t\txxdiff -X --show-merged-pane \\\n+\t\t\"$merge_tool_path\" -X --show-merged-pane \\\n \t\t    -R 'Accel.SaveAsMerged: \"Ctrl-S\"' \\\n \t\t    -R 'Accel.Search: \"Ctrl+F\"' \\\n \t\t    -R 'Accel.SearchForward: \"Ctrl-G\"' \\\n \t\t    --merged-file \"$path\" -- \"$LOCAL\" \"$BASE\" \"$REMOTE\"\n \t    else\n-\t\txxdiff -X --show-merged-pane \\\n+\t\t\"$merge_tool_path\" -X --show-merged-pane \\\n \t\t    -R 'Accel.SaveAsMerged: \"Ctrl-S\"' \\\n \t\t    -R 'Accel.Search: \"Ctrl+F\"' \\\n \t\t    -R 'Accel.SearchForward: \"Ctrl-G\"' \\\n@@ -243,18 +243,18 @@ merge_file () {\n \topendiff)\n \t    touch \"$BACKUP\"\n \t    if base_present; then\n-\t\topendiff \"$LOCAL\" \"$REMOTE\" -ancestor \"$BASE\" -merge \"$path\" | cat\n+\t\t\"$merge_tool_path\" \"$LOCAL\" \"$REMOTE\" -ancestor \"$BASE\" -merge \"$path\" | cat\n \t    else\n-\t\topendiff \"$LOCAL\" \"$REMOTE\" -merge \"$path\" | cat\n+\t\t\"$merge_tool_path\" \"$LOCAL\" \"$REMOTE\" -merge \"$path\" | cat\n \t    fi\n \t    check_unchanged\n \t    save_backup\n \t    ;;\n \temerge)\n \t    if base_present ; then\n-\t\temacs -f emerge-files-with-ancestor-command \"$LOCAL\" \"$REMOTE\" \"$BASE\" \"$(basename \"$path\")\"\n+\t\t\"$merge_tool_path\" -f emerge-files-with-ancestor-command \"$LOCAL\" \"$REMOTE\" \"$BASE\" \"$(basename \"$path\")\"\n \t    else\n-\t\temacs -f emerge-files-command \"$LOCAL\" \"$REMOTE\" \"$(basename \"$path\")\"\n+\t\t\"$merge_tool_path\" -f emerge-files-command \"$LOCAL\" \"$REMOTE\" \"$(basename \"$path\")\"\n \t    fi\n \t    status=$?\n \t    save_backup\n@@ -297,17 +297,23 @@ do\n     shift\n done\n \n+valid_tool() {\n+\tcase \"$1\" in\n+\t\tkdiff3 | tkdiff | xxdiff | meld | opendiff | emerge | vimdiff | gvimdiff)\n+\t\t\t;; # happy\n+\t\t*)\n+\t\t\treturn 1\n+\t\t\t;;\n+\tesac\n+}\n+\n if test -z \"$merge_tool\"; then\n     merge_tool=`git config merge.tool`\n-    case \"$merge_tool\" in\n-\tkdiff3 | tkdiff | xxdiff | meld | opendiff | emerge | vimdiff | gvimdiff | \"\")\n-\t    ;; # happy\n-\t*)\n+    test -n \"$merge_tool\" || valid_tool \"$merge_tool\" || {\n \t    echo >&2 \"git config option merge.tool set to unknown tool: $merge_tool\"\n \t    echo >&2 \"Resetting to default...\"\n \t    unset merge_tool\n-\t    ;;\n-    esac\n+    }\n fi\n \n if test -z \"$merge_tool\" ; then\n@@ -345,24 +351,29 @@ if test -z \"$merge_tool\" ; then\n     fi\n fi\n \n-case \"$merge_tool\" in\n-    kdiff3|tkdiff|meld|xxdiff|vimdiff|gvimdiff|opendiff)\n-\tif ! type \"$merge_tool\" > /dev/null 2>&1; then\n-\t    echo \"The merge tool $merge_tool is not available\"\n-\t    exit 1\n-\tfi\n-\t;;\n-    emerge)\n-\tif ! type \"emacs\" > /dev/null 2>&1; then\n-\t    echo \"Emacs is not available\"\n-\t    exit 1\n-\tfi\n-\t;;\n-    *)\n-\techo \"Unknown merge tool: $merge_tool\"\n+valid_tool \"$merge_tool\" || {\n+\techo >&2 \"Unknown merge_tool $merge_tool\"\n \texit 1\n-\t;;\n-esac\n+}\n+\n+if test -z \"$merge_tool_path\" ; then\n+\tmerge_tool_path=`git config merge.${merge_tool}path`\n+\tif test -z \"$merge_tool_path\" ; then\n+\t\tcase \"$merge_tool\" in\n+\t\t\temerge)\n+\t\t\t\tmerge_tool_path=emacs\n+\t\t\t\t;;\n+\t\t\t*)\n+\t\t\t\tmerge_tool_path=$merge_tool\n+\t\t\t\t;;\n+\t\tesac\n+\tfi\n+fi\n+\n+if ! type \"$merge_tool_path\" > /dev/null 2>&1; then\n+    echo \"The merge tool $merge_tool is not available as '$merge_tool_path'\"\n+    exit 1\n+fi\n \n if test $# -eq 0 ; then\n \tfiles=`git ls-files -u | sed -e 's/^[^\t]*\t//' | sort -u`\n-- \n1.5.3.3.127.g40d17\n"},{"id":"55209","messageId":"11918785611059-git-send-email-prohaska@zib.de","threadId":"10195","inReplyTo":"11918785613855-git-send-email-prohaska@zib.de","subject":"[PATCH] mergetool: add support for ECMerge","fromName":"Steffen Prohaska","fromEmail":"prohaska@zib.de","sentAt":"2007-10-08T21:22:41Z","receivedAt":"2007-10-08T21:22:41Z","isPatch":true,"sender":{"key":"prohaska@zib.de","avatar":"https://avatars.githubusercontent.com/u/217580?v=4"},"body":"Add support for ECMerge available from\nhttp://www.elliecomputing.com/Products/merge_overview.asp\n\nSigned-off-by: Steffen Prohaska <prohaska@zib.de>\n---\n Documentation/git-mergetool.txt |    2 +-\n git-mergetool.sh                |   12 +++++++++++-\n 2 files changed, 12 insertions(+), 2 deletions(-)\n\ndiff --git a/Documentation/git-mergetool.txt b/Documentation/git-mergetool.txt\nindex 6b97aaa..ece7718 100644\n--- a/Documentation/git-mergetool.txt\n+++ b/Documentation/git-mergetool.txt\n@@ -25,7 +25,7 @@ OPTIONS\n -t or --tool=<tool>::\n \tUse the merge resolution program specified by <tool>.\n \tValid merge tools are:\n-\tkdiff3, tkdiff, meld, xxdiff, emerge, vimdiff, gvimdiff, and opendiff\n+\tkdiff3, tkdiff, meld, xxdiff, emerge, vimdiff, gvimdiff, ecmerge, and opendiff\n +\n If a merge resolution program is not specified, 'git mergetool'\n will use the configuration variable merge.tool.  If the\ndiff --git a/git-mergetool.sh b/git-mergetool.sh\nindex 7f6c16f..39f6595 100755\n--- a/git-mergetool.sh\n+++ b/git-mergetool.sh\n@@ -250,6 +250,16 @@ merge_file () {\n \t    check_unchanged\n \t    save_backup\n \t    ;;\n+\tecmerge)\n+\t    touch \"$BACKUP\"\n+\t    if base_present; then\n+\t\t\"$merge_tool_path\" \"$BASE\" \"$LOCAL\" \"$REMOTE\" --mode=merge3 --to=\"$path\"\n+\t    else\n+\t\t\"$merge_tool_path\" \"$LOCAL\" \"$REMOTE\" --mode=merge2 --to=\"$path\"\n+\t    fi\n+\t    check_unchanged\n+\t    save_backup\n+\t    ;;\n \temerge)\n \t    if base_present ; then\n \t\t\"$merge_tool_path\" -f emerge-files-with-ancestor-command \"$LOCAL\" \"$REMOTE\" \"$BASE\" \"$(basename \"$path\")\"\n@@ -299,7 +309,7 @@ done\n \n valid_tool() {\n \tcase \"$1\" in\n-\t\tkdiff3 | tkdiff | xxdiff | meld | opendiff | emerge | vimdiff | gvimdiff)\n+\t\tkdiff3 | tkdiff | xxdiff | meld | opendiff | emerge | vimdiff | gvimdiff | ecmerge)\n \t\t\t;; # happy\n \t\t*)\n \t\t\treturn 1\n-- \n1.5.3.3.127.g40d17\n"},{"id":"55211","messageId":"20071008214451.GB31713@thunk.org","threadId":"10195","inReplyTo":"11918785611059-git-send-email-prohaska@zib.de","subject":"Re: [PATCH] mergetool: add support for ECMerge","fromName":"Theodore Tso","fromEmail":"tytso@mit.edu","sentAt":"2007-10-08T21:44:51Z","receivedAt":"2007-10-08T21:44:51Z","isPatch":true,"sender":{"key":"tytso@mit.edu","avatar":"https://avatars.githubusercontent.com/u/51416?v=4"},"body":"On Mon, Oct 08, 2007 at 11:22:41PM +0200, Steffen Prohaska wrote:\n> Add support for ECMerge available from\n> http://www.elliecomputing.com/Products/merge_overview.asp\n\nHmm.  A propietary merge tool.  It's not that much code, so I guess....\n\nI note though that it claims on the web page that they are integrated\nwith \"most famous SCM's\", but they don't include git.  If we add this\nsupport, are they going to change their web page?  :-)\n\nAlso, ECmerge is supported on Linux, Solaris, MacOS X, and Windows.\nWhich platforms have you tested on?  My guess is that if it works on\nLinux, it'll probably work on Solaris and MacOS, but is it a fair\nguess you haven't tested under Windows?  Not that most Windows systems\nare going to be able to use git-mergetool since it's a bash script,\nunless they are using Cygwin or some such.\n\n       \t    \t      \t     \t     - Ted\n"},{"id":"55212","messageId":"20071008215729.GC31713@thunk.org","threadId":"10195","inReplyTo":"11918785613855-git-send-email-prohaska@zib.de","subject":"Re: [PATCH] mergetool: support absolute paths to tools by git config merge.<tool>path","fromName":"Theodore Tso","fromEmail":"tytso@mit.edu","sentAt":"2007-10-08T21:57:29Z","receivedAt":"2007-10-08T21:57:29Z","isPatch":true,"sender":{"key":"tytso@mit.edu","avatar":"https://avatars.githubusercontent.com/u/51416?v=4"},"body":"On Mon, Oct 08, 2007 at 11:22:40PM +0200, Steffen Prohaska wrote:\n> This commit adds a mechanism to provide absolute paths to the\n> commands called by 'git mergetool'. A path can be specified\n> in the configuation variable merge.<toolname>path.\n\nThis patch doesn't work the config file doesn't specify an explicit\nmergetool via merge.tool.   The reason for that is this loop:\n\n    for i in $merge_tool_candidates; do\n        if test $i = emerge ; then\n            cmd=emacs\n        else\n            cmd=$i\n        fi\n        if type $cmd > /dev/null 2>&1; then\n            merge_tool=$i\n            break\n        fi\n    done\n\nis only checking to see if $cmd is in the path; it's not looking up\nthe merge.<toolname>path variable in this loop.\n\nI guess the other question is whether we would be better off simply\ntelling the user to specify an absolute pathname in merge.tool, and\nthen having git-mergetool strip off the directory path via basename,\nand then on window systems, stripping off the .EXE or .COM suffix, and\nthen downcasing the name so that something like \"C:\\Program\nFiles\\ECMerge\\ECMerge.exe\" gets translated to \"ecmerge\".  Would I be\nright in guessing that the reason why you used merge.<toolname>path\napproach was to avoid this messy headache?\n\n\t\t\t\t\t- Ted\n"},{"id":"55213","messageId":"20071008220025.GZ31659@planck.djpig.de","threadId":"10195","inReplyTo":"11918785613855-git-send-email-prohaska@zib.de","subject":"Re: [PATCH] mergetool: support absolute paths to tools by git config merge.<tool>path","fromName":"Frank Lichtenheld","fromEmail":"frank@lichtenheld.de","sentAt":"2007-10-08T22:00:25Z","receivedAt":"2007-10-08T22:00:25Z","isPatch":true,"sender":{"key":"frank@lichtenheld.de","avatar":"https://gravatar.com/avatar/b9f1d4b120e138f157c9e480d0818197c474628923786adb98f30017cdb99c3c?d=mp&s=160"},"body":"On Mon, Oct 08, 2007 at 11:22:40PM +0200, Steffen Prohaska wrote:\n> This commit adds a mechanism to provide absolute paths to the\n> commands called by 'git mergetool'. A path can be specified\n> in the configuation variable merge.<toolname>path.\n\nWhy not merge.<toolname>.path?\nThis would it make easy to introduce new variables of the form\nmerge.<toolname>.<var> later if needed. I also think it is more\nconsistent with names of existing configuration variables.\n(think branch.<name>.<var> or remote.<name>.<var>)\n\nGruesse,\n-- \nFrank Lichtenheld <frank@lichtenheld.de>\nwww: http://www.djpig.de/\n"},{"id":"55214","messageId":"20071008220123.GD31713@thunk.org","threadId":"10195","inReplyTo":"20071008215729.GC31713@thunk.org","subject":"Re: [PATCH] mergetool: support absolute paths to tools by git config merge.<tool>path","fromName":"Theodore Tso","fromEmail":"tytso@mit.edu","sentAt":"2007-10-08T22:01:23Z","receivedAt":"2007-10-08T22:01:23Z","isPatch":true,"sender":{"key":"tytso@mit.edu","avatar":"https://avatars.githubusercontent.com/u/51416?v=4"},"body":"On Mon, Oct 08, 2007 at 05:57:29PM -0400, Theodore Tso wrote:\n> This patch doesn't work the config file doesn't specify an explicit\n> mergetool via merge.tool.   The reason for that is this loop:\n\nErr, let me try that again.  \"This patch doesn't work IF the config\nfile doesn't specify an explicit > mergetool via merge.tool.\"\n\nSorry about the missing conjuction; the sentence doesn't make much\nsense without it...\n\n\t\t\t\t\t\t- Ted\n"},{"id":"55229","messageId":"1C50C046-3D61-4D55-8D38-B2D563C1FF2A@zib.de","threadId":"10195","inReplyTo":"20071008214451.GB31713@thunk.org","subject":"Re: [PATCH] mergetool: add support for ECMerge","fromName":"Steffen Prohaska","fromEmail":"prohaska@zib.de","sentAt":"2007-10-09T06:14:24Z","receivedAt":"2007-10-09T06:14:24Z","isPatch":true,"sender":{"key":"prohaska@zib.de","avatar":"https://avatars.githubusercontent.com/u/217580?v=4"},"body":"\nOn Oct 8, 2007, at 11:44 PM, Theodore Tso wrote:\n\n> On Mon, Oct 08, 2007 at 11:22:41PM +0200, Steffen Prohaska wrote:\n>> Add support for ECMerge available from\n>> http://www.elliecomputing.com/Products/merge_overview.asp\n>\n> Hmm.  A propietary merge tool.  It's not that much code, so I  \n> guess....\n>\n> I note though that it claims on the web page that they are integrated\n> with \"most famous SCM's\", but they don't include git.  If we add this\n> support, are they going to change their web page?  :-)\n\nYou may even apply for a free (as beer) license if you contribute\nto open source projects:\n\nhttp://www.elliecomputing.com/Community/opensource.asp\n\nI didn't try this, so I can't say how this works in practice.\n\n> Also, ECmerge is supported on Linux, Solaris, MacOS X, and Windows.\n> Which platforms have you tested on?\n\nWindows. Haven't tested Unix systems yet.\n\n> My guess is that if it works on\n> Linux, it'll probably work on Solaris and MacOS, but is it a fair\n> guess you haven't tested under Windows?  Not that most Windows systems\n> are going to be able to use git-mergetool since it's a bash script,\n> unless they are using Cygwin or some such.\n\nI work on the msysgit project and I'd like to have mergetool\navailable before I advertise git on Windows. It makes merging\nso much easier ;)\n\n\tSteffen\n"},{"id":"55230","messageId":"C52FC9BE-13EE-4CB7-A5E9-164A2AC0E2E7@zib.de","threadId":"10195","inReplyTo":"20071008215729.GC31713@thunk.org","subject":"Re: [PATCH] mergetool: support absolute paths to tools by git config merge.<tool>path","fromName":"Steffen Prohaska","fromEmail":"prohaska@zib.de","sentAt":"2007-10-09T06:30:39Z","receivedAt":"2007-10-09T06:30:39Z","isPatch":true,"sender":{"key":"prohaska@zib.de","avatar":"https://avatars.githubusercontent.com/u/217580?v=4"},"body":"\nOn Oct 8, 2007, at 11:57 PM, Theodore Tso wrote:\n\n> On Mon, Oct 08, 2007 at 11:22:40PM +0200, Steffen Prohaska wrote:\n>> This commit adds a mechanism to provide absolute paths to the\n>> commands called by 'git mergetool'. A path can be specified\n>> in the configuation variable merge.<toolname>path.\n>\n> This patch doesn't work if the config file doesn't specify an explicit\n> mergetool via merge.tool.   The reason for that is this loop:\n>\n>     for i in $merge_tool_candidates; do\n>         if test $i = emerge ; then\n>             cmd=emacs\n>         else\n>             cmd=$i\n>         fi\n>         if type $cmd > /dev/null 2>&1; then\n>             merge_tool=$i\n>             break\n>         fi\n>     done\n>\n> is only checking to see if $cmd is in the path; it's not looking up\n> the merge.<toolname>path variable in this loop.\n\nI didn't change the automatic detection. It should work as before.\nThat is it continues to assume that merge tools are in PATH.\n\nIs you expectation that git-mergetool should also consider the\nabsolute paths provided in merge.<toolname>path?\n\nWhen I wrote the patch I had in mind that people will set the\nmerge.tool explicitly if they provide an absolute path. Automatic\ndetection would only be used if nothing is configured. In this\ncase a tool must be in PATH or would not be found.\n\n\n> I guess the other question is whether we would be better off simply\n> telling the user to specify an absolute pathname in merge.tool, and\n> then having git-mergetool strip off the directory path via basename,\n> and then on window systems, stripping off the .EXE or .COM suffix, and\n> then downcasing the name so that something like \"C:\\Program\n> Files\\ECMerge\\ECMerge.exe\" gets translated to \"ecmerge\".  Would I be\n> right in guessing that the reason why you used merge.<toolname>path\n> approach was to avoid this messy headache?\n\nYes. The program to start ECMerge on Windows is called 'guimerge.exe'.\nHard to derive a sensible short name from this.\n\nSo I don't think that an automatic translation is an option. I prefer\nto provide the absolute paths.\n\nAbsolute paths have another advantage. You can set several of them\nand choose a tool on the command line. Maybe you have several tools\nyou want to try. Or you hacking with someone else who preferes a\ndifferent tool. Or you just want to give a demo. I see\nmerge.<toolname>path more as a database associating absolute paths\nwith the shortnames.\n\nMy mental model is as follows:\n1) merge.tool selects the mechanism needed to call the tool, that is\ncommand line arguments, how merge result is passed, ...\n2) merge.<toolname>path provides additional information how to locate\nthe selected tool in the filesystem.\n\nThe two points are somewhat orthogonal. I'd not fuse them into one.\n\n\tSteffen\n"},{"id":"55232","messageId":"9505CF7F-2024-48A8-88B0-0410DB2572B6@zib.de","threadId":"10195","inReplyTo":"20071008220025.GZ31659@planck.djpig.de","subject":"Re: [PATCH] mergetool: support absolute paths to tools by git config merge.<tool>path","fromName":"Steffen Prohaska","fromEmail":"prohaska@zib.de","sentAt":"2007-10-09T06:42:17Z","receivedAt":"2007-10-09T06:42:17Z","isPatch":true,"sender":{"key":"prohaska@zib.de","avatar":"https://avatars.githubusercontent.com/u/217580?v=4"},"body":"\nOn Oct 9, 2007, at 12:00 AM, Frank Lichtenheld wrote:\n\n> On Mon, Oct 08, 2007 at 11:22:40PM +0200, Steffen Prohaska wrote:\n>> This commit adds a mechanism to provide absolute paths to the\n>> commands called by 'git mergetool'. A path can be specified\n>> in the configuation variable merge.<toolname>path.\n>\n> Why not merge.<toolname>.path?\n>\n> This would it make easy to introduce new variables of the form\n> merge.<toolname>.<var> later if needed. I also think it is more\n> consistent with names of existing configuration variables.\n> (think branch.<name>.<var> or remote.<name>.<var>)\n\nLooks more beautiful on the command line but a bit more complex\nin the config file. But I like the idea.\n\nMaybe mergetool.<tool>.path is even a better choice? It clearly\nindicate the relationship with mergetool. We could explain:\n\n'The variable merge.tool = <tool> refers to a tool that can\nbe further specified in mergetool.<tool>.path.'\n\n\tSteffen\n"},{"id":"55261","messageId":"Pine.LNX.4.64.0710091334390.4174@racer.site","threadId":"10195","inReplyTo":"11918785613855-git-send-email-prohaska@zib.de","subject":"Re: [PATCH] mergetool: support absolute paths to tools by git config merge.<tool>path","fromName":"Johannes Schindelin","fromEmail":"johannes.schindelin@gmx.de","sentAt":"2007-10-09T12:35:30Z","receivedAt":"2007-10-09T12:35:30Z","isPatch":true,"sender":{"key":"johannes.schindelin@gmx.de","avatar":"https://avatars.githubusercontent.com/u/127790?v=4"},"body":"Hi,\n\nOn Mon, 8 Oct 2007, Steffen Prohaska wrote:\n\n> This commit adds a mechanism to provide absolute paths to the\n> commands called by 'git mergetool'. A path can be specified\n> in the configuation variable merge.<toolname>path.\n\nWould it not be more in line with all other config variables if it was \nwritten merge.<toolname>.path?  (Indeed, I thought your subject line \ncontained a typo when I read it first.)\n\nCiao,\nDscho\n"},{"id":"55262","messageId":"Pine.LNX.4.64.0710091335580.4174@racer.site","threadId":"10195","inReplyTo":"1C50C046-3D61-4D55-8D38-B2D563C1FF2A@zib.de","subject":"Re: [PATCH] mergetool: add support for ECMerge","fromName":"Johannes Schindelin","fromEmail":"johannes.schindelin@gmx.de","sentAt":"2007-10-09T12:37:40Z","receivedAt":"2007-10-09T12:37:40Z","isPatch":true,"sender":{"key":"johannes.schindelin@gmx.de","avatar":"https://avatars.githubusercontent.com/u/127790?v=4"},"body":"Hi,\n\nOn Tue, 9 Oct 2007, Steffen Prohaska wrote:\n\n> I work on the msysgit project and I'd like to have mergetool available \n> before I advertise git on Windows. It makes merging so much easier ;)\n\nI would _hate_ to rely on a closed source program (in addition to Windows \nitself) in msysGit.\n\nAnd it seems that you cannot even get ECMerge for free in general.\n\nWhat does TortoiseCVS use?\n\nCiao,\nDscho\n"},{"id":"55265","messageId":"A3F377CC-DCAB-42E0-8522-8A1D6EE735E9@zib.de","threadId":"10195","inReplyTo":"Pine.LNX.4.64.0710091335580.4174@racer.site","subject":"Re: [PATCH] mergetool: add support for ECMerge","fromName":"Steffen Prohaska","fromEmail":"prohaska@zib.de","sentAt":"2007-10-09T12:49:52Z","receivedAt":"2007-10-09T12:49:52Z","isPatch":true,"sender":{"key":"prohaska@zib.de","avatar":"https://avatars.githubusercontent.com/u/217580?v=4"},"body":"\nOn Oct 9, 2007, at 2:37 PM, Johannes Schindelin wrote:\n\n> On Tue, 9 Oct 2007, Steffen Prohaska wrote:\n>\n>> I work on the msysgit project and I'd like to have mergetool  \n>> available\n>> before I advertise git on Windows. It makes merging so much easier ;)\n>\n> I would _hate_ to rely on a closed source program (in addition to  \n> Windows\n> itself) in msysGit.\n\nIt's only an option. You can also choose kdiff3 if you like, or  \nvimdiff or\nemacs merge. But personally, I prefer ECMerge because is seems to  \nsupport\na faster and safer workflow (at least for me).\n\nBefore submitted this patch I thought about a general mechanism to  \neasily\nspecify any tool that supports command line argument. But just adding  \nthem\ntool by tool as needed looks easier to me, and hopefully to the user. We\ncan include the correct command line in git-mergetool and only require\nthe location of the program from the user.\n\n\n> And it seems that you cannot even get ECMerge for free in general.\n\nTrue. But does it matter? I can't get Windows for free and git runs  \non it.\n\n\n> What does TortoiseCVS use?\n\nDon't know.\n\n\tSteffen\n"},{"id":"55271","messageId":"2b3a6fcd0710090603l3c3578caq3bfa6a1b8ec583f@mail.gmail.com","threadId":"10195","inReplyTo":"Pine.LNX.4.64.0710091335580.4174@racer.site","subject":"Re: [PATCH] mergetool: add support for ECMerge","fromName":"Alan Hadsell","fromEmail":"ahadsell@gmail.com","sentAt":"2007-10-09T13:03:40Z","receivedAt":"2007-10-09T13:03:40Z","isPatch":true,"sender":{"key":"ahadsell@gmail.com","avatar":null},"body":"On 10/9/07, Johannes Schindelin <Johannes.Schindelin@gmx.de> wrote:\n\n> What does TortoiseCVS use?\n\nThey don't actually include it in the package, but they recommend\nWinMerge http://winmerge.org/, which is free (GPL).\n\n-- \nAlan Hadsell\n"},{"id":"55276","messageId":"236E44B5-361E-4CE3-8C3D-BDAD0569642E@zib.de","threadId":"10195","inReplyTo":"2b3a6fcd0710090603l3c3578caq3bfa6a1b8ec583f@mail.gmail.com","subject":"Re: [PATCH] mergetool: add support for ECMerge","fromName":"Steffen Prohaska","fromEmail":"prohaska@zib.de","sentAt":"2007-10-09T13:17:24Z","receivedAt":"2007-10-09T13:17:24Z","isPatch":true,"sender":{"key":"prohaska@zib.de","avatar":"https://avatars.githubusercontent.com/u/217580?v=4"},"body":"\nOn Oct 9, 2007, at 3:03 PM, Alan Hadsell wrote:\n\n> On 10/9/07, Johannes Schindelin <Johannes.Schindelin@gmx.de> wrote:\n>\n>> What does TortoiseCVS use?\n>\n> They don't actually include it in the package, but they recommend\n> WinMerge http://winmerge.org/, which is free (GPL).\n\nWinMerge doesn't support 3-way merges. At least I cannot find any\nindication for 3-way in the manual [1] and the comparison at [2] also\ntells that WinMerge doesn't support 3-way.\n\n\tSteffen\n\n[1] http://winmerge.org/2.6/manual/CompareFiles.html\n[2] http://en.wikipedia.org/wiki/Comparison_of_file_comparison_tools\n"},{"id":"55285","messageId":"2b3a6fcd0710090721p28891ec0r5f385ff6fd1465c4@mail.gmail.com","threadId":"10195","inReplyTo":"236E44B5-361E-4CE3-8C3D-BDAD0569642E@zib.de","subject":"Re: [PATCH] mergetool: add support for ECMerge","fromName":"Alan Hadsell","fromEmail":"ahadsell@gmail.com","sentAt":"2007-10-09T14:21:27Z","receivedAt":"2007-10-09T14:21:27Z","isPatch":true,"sender":{"key":"ahadsell@gmail.com","avatar":null},"body":"Steffen Prohaska writes:\n\n> WinMerge doesn't support 3-way merges. At least I cannot find any\n> indication for 3-way in the manual [1] and the comparison at [2] also\n> tells that WinMerge doesn't support 3-way.\n\n>From their FAQ:\n\nDoes WinMerge support merging three files? Sometimes it is called\n3-way merge, where one file is ancestor. This would be useful for\nversion control!\n\nUnfortunately not. We acknowledge it would be good feature but have no\nplans to implement it in near future. This can be somewhat worked\naround by using two WinMerge instances. (One developer has begun\npreliminary work on this feature, but it is not yet available, even in\nexperimental releases.)\n"}]}