{"thread":{"id":"19163","subject":"[PATCH] mergetool--lib: add support for araxis merge","startedAt":"2009-05-03T01:18:01Z","lastAt":"2009-05-09T20:56:30Z","messageCount":7,"participants":["David Aguilar","Markus Heidelberg","Johannes Schindelin"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"112901","messageId":"1241313481-17923-1-git-send-email-davvid@gmail.com","threadId":"19163","inReplyTo":null,"subject":"[PATCH] mergetool--lib: add support for araxis merge","fromName":"David Aguilar","fromEmail":"davvid@gmail.com","sentAt":"2009-05-03T01:18:01Z","receivedAt":"2009-05-03T01:18:01Z","isPatch":true,"sender":{"key":"davvid@gmail.com","avatar":"https://avatars.githubusercontent.com/u/13196?v=4"},"body":"Araxis merge is now a built-in diff/merge tool.\nThis adds araxis to git-completion and updates\nthe documentation as well.\n\nSigned-off-by: David Aguilar <davvid@gmail.com>\n---\n\nThis patch is a result of the discussion on the msysgit list:\n\nhttp://groups.google.com/group/msysgit/browse_thread/thread/fa353fa2240594d7\n\n'compare' is the command-line utility that is provided\non MacOS.  Users on other platforms may have to manually\nset their mergetool.araxis.path.\n\n\n Documentation/git-difftool.txt         |    2 +-\n Documentation/git-mergetool.txt        |    2 +-\n Documentation/merge-config.txt         |    2 +-\n contrib/completion/git-completion.bash |    2 +-\n git-mergetool--lib.sh                  |   24 ++++++++++++++++++++++--\n 5 files changed, 26 insertions(+), 6 deletions(-)\n\ndiff --git a/Documentation/git-difftool.txt b/Documentation/git-difftool.txt\nindex 15b247b..96a6c51 100644\n--- a/Documentation/git-difftool.txt\n+++ b/Documentation/git-difftool.txt\n@@ -31,7 +31,7 @@ OPTIONS\n \tUse the diff tool specified by <tool>.\n \tValid merge tools are:\n \tkdiff3, kompare, tkdiff, meld, xxdiff, emerge, vimdiff, gvimdiff,\n-\tecmerge, diffuse and opendiff\n+\tecmerge, diffuse, opendiff and araxis.\n +\n If a diff tool is not specified, 'git-difftool'\n will use the configuration variable `diff.tool`.  If the\ndiff --git a/Documentation/git-mergetool.txt b/Documentation/git-mergetool.txt\nindex ff9700d..68ed6c0 100644\n--- a/Documentation/git-mergetool.txt\n+++ b/Documentation/git-mergetool.txt\n@@ -27,7 +27,7 @@ OPTIONS\n \tUse the merge resolution program specified by <tool>.\n \tValid merge tools are:\n \tkdiff3, tkdiff, meld, xxdiff, emerge, vimdiff, gvimdiff, ecmerge,\n-\tdiffuse, tortoisemerge and opendiff\n+\tdiffuse, tortoisemerge, opendiff and araxis.\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/Documentation/merge-config.txt b/Documentation/merge-config.txt\nindex 4832bc7..c0f96e7 100644\n--- a/Documentation/merge-config.txt\n+++ b/Documentation/merge-config.txt\n@@ -23,7 +23,7 @@ merge.tool::\n \tControls which merge resolution program is used by\n \tlinkgit:git-mergetool[1].  Valid built-in values are: \"kdiff3\",\n \t\"tkdiff\", \"meld\", \"xxdiff\", \"emerge\", \"vimdiff\", \"gvimdiff\",\n-\t\"diffuse\", \"ecmerge\", \"tortoisemerge\", and\n+\t\"diffuse\", \"ecmerge\", \"tortoisemerge\", \"araxis\", and\n \t\"opendiff\".  Any other value is treated is custom merge tool\n \tand there must be a corresponding mergetool.<tool>.cmd option.\n \ndiff --git a/contrib/completion/git-completion.bash b/contrib/completion/git-completion.bash\nindex 1a90cb8..dfd128b 100755\n--- a/contrib/completion/git-completion.bash\n+++ b/contrib/completion/git-completion.bash\n@@ -911,7 +911,7 @@ _git_diff ()\n }\n \n __git_mergetools_common=\"diffuse ecmerge emerge kdiff3 meld opendiff\n-\t\t\ttkdiff vimdiff gvimdiff xxdiff\n+\t\t\ttkdiff vimdiff gvimdiff xxdiff araxis\n \"\n \n _git_difftool ()\ndiff --git a/git-mergetool--lib.sh b/git-mergetool--lib.sh\nindex a16a279..f3c63ef 100644\n--- a/git-mergetool--lib.sh\n+++ b/git-mergetool--lib.sh\n@@ -18,6 +18,9 @@ translate_merge_tool_path () {\n \temerge)\n \t\techo emacs\n \t\t;;\n+\taraxis)\n+\t\techo compare\n+\t\t;;\n \t*)\n \t\techo \"$1\"\n \t\t;;\n@@ -43,7 +46,7 @@ check_unchanged () {\n valid_tool () {\n \tcase \"$1\" in\n \tkdiff3 | tkdiff | xxdiff | meld | opendiff | \\\n-\temerge | vimdiff | gvimdiff | ecmerge | diffuse)\n+\temerge | vimdiff | gvimdiff | ecmerge | diffuse | araxis)\n \t\t;; # happy\n \ttortoisemerge)\n \t\tif ! merge_mode; then\n@@ -263,6 +266,23 @@ run_merge_tool () {\n \t\t\tstatus=1\n \t\tfi\n \t\t;;\n+\taraxis)\n+\t\tif merge_mode; then\n+\t\t\tif $base_present; then\n+\t\t\t\t\"$merge_tool_path\" -wait -merge -3 -a1 \\\n+\t\t\t\t\t\"$BASE\" \"$LOCAL\" \"$REMOTE\" \"$MERGED\" \\\n+\t\t\t\t\t>/dev/null 2>&1\n+\t\t\telse\n+\t\t\t\t\"$merge_tool_path\" -wait -2 \\\n+\t\t\t\t\t\"$LOCAL\" \"$REMOTE\" \"$MERGED\" \\\n+\t\t\t\t\t>/dev/null 2>&1\n+\t\t\tfi\n+\t\t\tcheck_unchanged\n+\t\telse\n+\t\t\t\"$merge_tool_path\" -wait -2 \"$LOCAL\" \"$REMOTE\" \\\n+\t\t\t\t>/dev/null 2>&1\n+\t\tfi\n+\t\t;;\n \t*)\n \t\tmerge_tool_cmd=\"$(get_merge_tool_cmd \"$1\")\"\n \t\tif test -z \"$merge_tool_cmd\"; then\n@@ -302,7 +322,7 @@ guess_merge_tool () {\n \t\telse\n \t\t\ttools=\"opendiff kdiff3 tkdiff xxdiff meld $tools\"\n \t\tfi\n-\t\ttools=\"$tools gvimdiff diffuse ecmerge\"\n+\t\ttools=\"$tools gvimdiff diffuse ecmerge araxis\"\n \tfi\n \tif echo \"${VISUAL:-$EDITOR}\" | grep emacs > /dev/null 2>&1; then\n \t\t# $EDITOR is emacs so add emerge as a candidate\n-- \n1.6.3.rc4\n"},{"id":"112907","messageId":"200905030854.28059.markus.heidelberg@web.de","threadId":"19163","inReplyTo":"1241313481-17923-1-git-send-email-davvid@gmail.com","subject":"Re: [PATCH] mergetool--lib: add support for araxis merge","fromName":"Markus Heidelberg","fromEmail":"markus.heidelberg@web.de","sentAt":"2009-05-03T06:54:27Z","receivedAt":"2009-05-03T06:54:27Z","isPatch":true,"sender":{"key":"markus.heidelberg@web.de","avatar":"https://avatars.githubusercontent.com/u/6334512?v=4"},"body":"David Aguilar, 03.05.2009:\n> This patch is a result of the discussion on the msysgit list:\n> \n> http://groups.google.com/group/msysgit/browse_thread/thread/fa353fa2240594d7\n> \n> diff --git a/git-mergetool--lib.sh b/git-mergetool--lib.sh\n> @@ -263,6 +266,23 @@ run_merge_tool () {\n>  \t\t\tstatus=1\n>  \t\tfi\n>  \t\t;;\n> +\taraxis)\n> +\t\tif merge_mode; then\n> +\t\t\tif $base_present; then\n\n\t\t\ttouch \"$BACKUP\"\n\n> +\t\t\t\t\"$merge_tool_path\" -wait -merge -3 -a1 \\\n> +\t\t\t\t\t\"$BASE\" \"$LOCAL\" \"$REMOTE\" \"$MERGED\" \\\n> +\t\t\t\t\t>/dev/null 2>&1\n> +\t\t\telse\n> +\t\t\t\t\"$merge_tool_path\" -wait -2 \\\n> +\t\t\t\t\t\"$LOCAL\" \"$REMOTE\" \"$MERGED\" \\\n> +\t\t\t\t\t>/dev/null 2>&1\n> +\t\t\tfi\n> +\t\t\tcheck_unchanged\n> +\t\telse\n> +\t\t\t\"$merge_tool_path\" -wait -2 \"$LOCAL\" \"$REMOTE\" \\\n> +\t\t\t\t>/dev/null 2>&1\n> +\t\tfi\n> +\t\t;;\n>  \t*)\n>  \t\tmerge_tool_cmd=\"$(get_merge_tool_cmd \"$1\")\"\n>  \t\tif test -z \"$merge_tool_cmd\"; then\n\nHaven't you included the -title[1-3] command line switches because of\nthe strange \"'title'\" format? The user on the msysgit list had commented\nit out in his patch, although he said it worked in this way. And looking\nat git-gui/lib/mergetool.tcl, it is done in the same way.\n\nMarkus\n"},{"id":"112920","messageId":"alpine.DEB.1.00.0905031629290.18521@pacific.mpi-cbg.de","threadId":"19163","inReplyTo":"1241313481-17923-1-git-send-email-davvid@gmail.com","subject":"Re: [PATCH] mergetool--lib: add support for araxis merge","fromName":"Johannes Schindelin","fromEmail":"johannes.schindelin@gmx.de","sentAt":"2009-05-03T14:30:30Z","receivedAt":"2009-05-03T14:30:30Z","isPatch":true,"sender":{"key":"johannes.schindelin@gmx.de","avatar":"https://avatars.githubusercontent.com/u/127790?v=4"},"body":"Hi,\n\nOn Sat, 2 May 2009, David Aguilar wrote:\n\n> Araxis merge is now a built-in diff/merge tool.\n> This adds araxis to git-completion and updates\n> the documentation as well.\n> \n> Signed-off-by: David Aguilar <davvid@gmail.com>\n> ---\n> \n> This patch is a result of the discussion on the msysgit list:\n> \n> http://groups.google.com/group/msysgit/browse_thread/thread/fa353fa2240594d7\n> \n> 'compare' is the command-line utility that is provided\n> on MacOS.  Users on other platforms may have to manually\n> set their mergetool.araxis.path.\n\nThe only reason I did not merge that patch sent to msysgit@googlegroups \nwas that I did not have _any_ confirmation that it works.\n\nDo you have any?  As Araxis is not free software, I refuse to touch it.\n\nCiao,\nDscho\n"},{"id":"112923","messageId":"20090503181824.GA50640@gmail.com","threadId":"19163","inReplyTo":"alpine.DEB.1.00.0905031629290.18521@pacific.mpi-cbg.de","subject":"Re: [PATCH] mergetool--lib: add support for araxis merge","fromName":"David Aguilar","fromEmail":"davvid@gmail.com","sentAt":"2009-05-03T18:18:24Z","receivedAt":"2009-05-03T18:18:24Z","isPatch":true,"sender":{"key":"davvid@gmail.com","avatar":"https://avatars.githubusercontent.com/u/13196?v=4"},"body":"On  0, Johannes Schindelin <Johannes.Schindelin@gmx.de> wrote:\n> Hi,\n> \n> On Sat, 2 May 2009, David Aguilar wrote:\n> \n> > Araxis merge is now a built-in diff/merge tool.\n> > This adds araxis to git-completion and updates\n> > the documentation as well.\n> > \n> > Signed-off-by: David Aguilar <davvid@gmail.com>\n> > ---\n> > \n> > This patch is a result of the discussion on the msysgit list:\n> > \n> > http://groups.google.com/group/msysgit/browse_thread/thread/fa353fa2240594d7\n> > \n> > 'compare' is the command-line utility that is provided\n> > on MacOS.  Users on other platforms may have to manually\n> > set their mergetool.araxis.path.\n> \n> The only reason I did not merge that patch sent to msysgit@googlegroups \n> was that I did not have _any_ confirmation that it works.\n> \n> Do you have any?  As Araxis is not free software, I refuse to touch it.\n> \n> Ciao,\n> Dscho\n\nI tested it (but not on windows).  It works.\nI have the same reservations about non-free software,\nbut at least they mention git on their homepage\n(even if it's only in their documentation).\n\n\n-- \n\t\tDavid\n"},{"id":"112924","messageId":"20090503182040.GB50640@gmail.com","threadId":"19163","inReplyTo":"200905030854.28059.markus.heidelberg@web.de","subject":"Re: [PATCH] mergetool--lib: add support for araxis merge","fromName":"David Aguilar","fromEmail":"davvid@gmail.com","sentAt":"2009-05-03T18:20:41Z","receivedAt":"2009-05-03T18:20:41Z","isPatch":true,"sender":{"key":"davvid@gmail.com","avatar":"https://avatars.githubusercontent.com/u/13196?v=4"},"body":"> David Aguilar, 03.05.2009:\n> > +\t\t\t\t\"$merge_tool_path\" -wait -merge -3 -a1 \\\n> > +\t\t\t\t\t\"$BASE\" \"$LOCAL\" \"$REMOTE\" \"$MERGED\" \\\n> > +\t\t\t\t\t>/dev/null 2>&1\n> > +\t\t\telse\n> > +\t\t\t\t\"$merge_tool_path\" -wait -2 \\\n> > +\t\t\t\t\t\"$LOCAL\" \"$REMOTE\" \"$MERGED\" \\\n> > +\t\t\t\t\t>/dev/null 2>&1\n> > +\t\t\tfi\n> > +\t\t\tcheck_unchanged\n> > +\t\telse\n> > +\t\t\t\"$merge_tool_path\" -wait -2 \"$LOCAL\" \"$REMOTE\" \\\n> > +\t\t\t\t>/dev/null 2>&1\n> > +\t\tfi\n> > +\t\t;;\n> \n> Haven't you included the -title[1-3] command line switches because of\n> the strange \"'title'\" format? The user on the msysgit list had commented\n> it out in his patch, although he said it worked in this way. And looking\n> at git-gui/lib/mergetool.tcl, it is done in the same way.\n> \n> Markus\n> \n\nI can resend with the title stuff.\nI didn't include it since it was commented out in the original\npatch.\n\n-- \n\t\tDavid\n"},{"id":"112941","messageId":"20090504000956.GD50640@gmail.com","threadId":"19163","inReplyTo":"200905030854.28059.markus.heidelberg@web.de","subject":"Re: [PATCH] mergetool--lib: add support for araxis merge","fromName":"David Aguilar","fromEmail":"davvid@gmail.com","sentAt":"2009-05-04T00:09:57Z","receivedAt":"2009-05-04T00:09:57Z","isPatch":true,"sender":{"key":"davvid@gmail.com","avatar":"https://avatars.githubusercontent.com/u/13196?v=4"},"body":"Markus Heidelberg <markus.heidelberg@web.de> wrote:\n> \n> Haven't you included the -title[1-3] command line switches because of\n> the strange \"'title'\" format? The user on the msysgit list had commented\n> it out in his patch, although he said it worked in this way. And looking\n> at git-gui/lib/mergetool.tcl, it is done in the same way.\n> \n> Markus\n\nI looked into it.\nWindows. :(\n\n-title1:\"nice stuff\" works great everywhere except for windows.\n-title1:\"'nice stuff'\" doesn't work there either.\nThat's probably why it was commented out in the original patch.\n\nOn windows we'd have to escape the spaces (wild guess) so the\noriginal patch is probably the best option since I don't feel\nlike making the other platforms suffer for it.\n\nSeeing .diff_XXXX as the filename is bad too (and that is a\nform of suffering as well) but it's a compromise since there\nis a possibility that we could fix that elsewhere to\neveryone's benefit.\n\nAs far as difftool is concerned, the code that generates\nthe temp filename is prep_temp_blob() in diff.c.\nIt's used by several callers that naturally care nothing\nabout filenames.\n\nIt would be nice to specialize the ext-diff code to\ngenerate a more intuitive filename.  Maybe something\nlike original_filename.XXXXX.ext instead of the current\n.diff_XXXXX.  Right now the choice of filename breaks\nsyntax highlighting in some viewers and also makes\nthe usage of --title args necessary since the default\nnames tell us nothing about what we're viewing.\n\nThat's definitely not the kind of thing to be thinking\nabout during an -rc cycle ;), though I would be interested\nin maybe working on that later if others agree that\nit's not a bad idea.\n\nIt wouldn't be perfect, but it would be just a\nlittle bit nicer for anyone that's using the tools\neveryday.\n\n-- \n\t\tDavid\n"},{"id":"113424","messageId":"200905092256.31964.markus.heidelberg@web.de","threadId":"19163","inReplyTo":"20090504000956.GD50640@gmail.com","subject":"Re: [PATCH] mergetool--lib: add support for araxis merge","fromName":"Markus Heidelberg","fromEmail":"markus.heidelberg@web.de","sentAt":"2009-05-09T20:56:30Z","receivedAt":"2009-05-09T20:56:30Z","isPatch":true,"sender":{"key":"markus.heidelberg@web.de","avatar":"https://avatars.githubusercontent.com/u/6334512?v=4"},"body":"David Aguilar, 04.05.2009:\n> Seeing .diff_XXXX as the filename is bad too\n\n> It would be nice to specialize the ext-diff code to\n> generate a more intuitive filename.  Maybe something\n> like original_filename.XXXXX.ext instead of the current\n> .diff_XXXXX.  Right now the choice of filename breaks\n> syntax highlighting in some viewers and also makes\n> the usage of --title args necessary since the default\n> names tell us nothing about what we're viewing.\n\nYes, this change would make sense.\n"}]}