{"thread":{"id":"20372","subject":"difftool, open all diff files immediately, not in serial","startedAt":"2009-08-04T20:49:04Z","lastAt":"2010-04-14T06:41:08Z","messageCount":6,"participants":["Seba Illingworth","Thomas Rast","Seb","David Aguilar"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"119516","messageId":"loom.20090804T204107-117@post.gmane.org","threadId":"20372","inReplyTo":null,"subject":"difftool, open all diff files immediately, not in serial","fromName":"Seba Illingworth","fromEmail":"seba.illingworth@gmail.com","sentAt":"2009-08-04T20:49:04Z","receivedAt":"2009-08-04T20:49:04Z","isPatch":false,"sender":{"key":"seba.illingworth@gmail.com","avatar":"https://gravatar.com/avatar/b60029c0c653904e427c724df5c87503e32aa187fcf20658089f1ed78b144996?d=mp&s=160"},"body":"The default git diff behavior is to open each diff file in serial \n(wait for previous file to be closed before opening next file).\n\nI'm looking for a way to open all the files at once - in BeyondCompare \nfor example this would open all the files in tabs within the same BC window.\n\nThis would make it easier to review a complex set of changes; \nflick back and forwards between the diff files and ignore \nunimportant files.\n\nHere's my same question on StackOverflow with a couple of ideas \nI have found (copy files to temp dir and do folder diff, Araxis \nhas 'nowait' option): \nhttp://stackoverflow.com/questions/1220309\n\n--Seba\n"},{"id":"119529","messageId":"200908042347.48705.trast@student.ethz.ch","threadId":"20372","inReplyTo":"loom.20090804T204107-117@post.gmane.org","subject":"Re: difftool, open all diff files immediately, not in serial","fromName":"Thomas Rast","fromEmail":"trast@student.ethz.ch","sentAt":"2009-08-04T21:47:46Z","receivedAt":"2009-08-04T21:47:46Z","isPatch":false,"sender":{"key":"tr@thomasrast.ch","avatar":"https://avatars.githubusercontent.com/u/153510?v=4"},"body":"Seba Illingworth wrote:\n> The default git diff behavior is to open each diff file in serial \n> (wait for previous file to be closed before opening next file).\n> \n> I'm looking for a way to open all the files at once - in BeyondCompare \n> for example this would open all the files in tabs within the same BC window.\n\nI posted the script below on IRC the other week[1] in reply to someone\nlooking for a way to do this for 'meld'.  I'm not sure this is the\n*fastest* way to do this, but I'm at least trying to take a few\nshortcuts ;-)\n\nSince this is now the second request for such a tool, it would be nice\nif you could at least shape this as a contrib/ patch (if it fits your\nneeds, of course).\n\n[1] http://colabti.org/irclogger/irclogger_log/git?date=2009-07-14#l2180\n\n-- 8< --\n#!/bin/sh\n\n. \"$(git --exec-path)/git-sh-setup\"\ncd_to_toplevel # for the tar below\n\npre=\"${1-HEAD}\"\npost=\"$2\"\n\ntmp=\"$(mktemp -d)\"\n\ncleanup () {\n\trm -rf $tmp\n}\n\ntrap cleanup EXIT\n\nmkdir \"$tmp\"/a \"$tmp\"/b\n\nif [ -n \"$post\" ]; then\n\tgit diff --name-only \"$pre\" \"$post\" > \"$tmp\"/filelist\n\twhile read name; do\n\t\tmkdir -p \"$tmp\"/b/\"$(dirname \"$name\")\"\n\t\tgit show \"$post\":\"$name\" > \"$tmp\"/b/\"$name\"\n\tdone < \"$tmp\"/filelist\nelse\n\tgit diff --name-only \"$pre\" > \"$tmp\"/filelist\n\ttar -c -T \"$tmp\"/filelist | (cd \"$tmp\"/b && tar -x)\nfi\n\nwhile read name; do\n\tmkdir -p \"$tmp\"/a/\"$(dirname \"$name\")\"\n\tgit show \"$pre\":\"$name\" > \"$tmp\"/a/\"$name\"\ndone < \"$tmp\"/filelist\n\ncd \"$tmp\"\n#meld a b\ndiff -ur a b\n"},{"id":"119539","messageId":"loom.20090804T224435-568@post.gmane.org","threadId":"20372","inReplyTo":"200908042347.48705.trast@student.ethz.ch","subject":"Re: difftool, open all diff files immediately, not in serial","fromName":"Seba Illingworth","fromEmail":"seba.illingworth@gmail.com","sentAt":"2009-08-04T22:52:05Z","receivedAt":"2009-08-04T22:52:05Z","isPatch":false,"sender":{"key":"seba.illingworth@gmail.com","avatar":"https://gravatar.com/avatar/b60029c0c653904e427c724df5c87503e32aa187fcf20658089f1ed78b144996?d=mp&s=160"},"body":"Thomas Rast <trast <at> student.ethz.ch> writes:\n\n> \n> I posted the script below on IRC the other week[1] in reply to someone\n> looking for a way to do this for 'meld'.\n...\n\nThanks Thomas, I'll take a few days to digest/test this \n(I'm new to bash and git) and give feedback.\n"},{"id":"121308","messageId":"loom.20090820T033212-722@post.gmane.org","threadId":"20372","inReplyTo":"200908042347.48705.trast@student.ethz.ch","subject":"Re: difftool, open all diff files immediately, not in serial","fromName":"Seba Illingworth","fromEmail":"seba.illingworth@gmail.com","sentAt":"2009-08-20T01:39:23Z","receivedAt":"2009-08-20T01:39:23Z","isPatch":false,"sender":{"key":"seba.illingworth@gmail.com","avatar":"https://gravatar.com/avatar/b60029c0c653904e427c724df5c87503e32aa187fcf20658089f1ed78b144996?d=mp&s=160"},"body":"Thomas Rast <trast <at> student.ethz.ch> writes:\n> I posted the script below on IRC the other week[1] in reply to someone\n> looking for a way to do this for 'meld'.  I'm not sure this is the\n> *fastest* way to do this, but I'm at least trying to take a few\n> shortcuts...\n\nI've come up with a simple script that diffs the files in a background task:\n\n  for name in $(git diff --name-only $1); do git difftool $1 $name & done\n\nThen aliased the script for usage:\n\n  git diffall [--staged]\n\nBeing a bash newbie, I'd appreciate any feedback on what seems to be \na simple solution...??\n"},{"id":"139445","messageId":"loom.20100414T040717-222@post.gmane.org","threadId":"20372","inReplyTo":"loom.20090804T224435-568@post.gmane.org","subject":"My solution","fromName":"Seb","fromEmail":"seba.illingworth@gmail.com","sentAt":"2010-04-14T02:16:07Z","receivedAt":"2010-04-14T02:16:07Z","isPatch":false,"sender":{"key":"seba.illingworth@gmail.com","avatar":"https://gravatar.com/avatar/b60029c0c653904e427c724df5c87503e32aa187fcf20658089f1ed78b144996?d=mp&s=160"},"body":"Seba Illingworth <seba.illingworth <at> gmail.com> writes:\n\n> \n> Thomas Rast <trast <at> student.ethz.ch> writes:\n> \n> > \n> > I posted the script below on IRC the other week[1] in reply to someone\n> > looking for a way to do this for 'meld'.\n> ...\n\nJust realised I never posted my solution. This works great for me, I wouldn't do \nwithout it:\nhttp://blog.codefarm.co.nz/2009/08/git-diff-and-difftool-open-all-files.html\n"},{"id":"139457","messageId":"20100414064107.GA3254@gmail.com","threadId":"20372","inReplyTo":"loom.20100414T040717-222@post.gmane.org","subject":"Re: My solution","fromName":"David Aguilar","fromEmail":"davvid@gmail.com","sentAt":"2010-04-14T06:41:08Z","receivedAt":"2010-04-14T06:41:08Z","isPatch":false,"sender":{"key":"davvid@gmail.com","avatar":"https://avatars.githubusercontent.com/u/13196?v=4"},"body":"On Wed, Apr 14, 2010 at 02:16:07AM +0000, Seb wrote:\n> Seba Illingworth <seba.illingworth <at> gmail.com> writes:\n> \n> > \n> > Thomas Rast <trast <at> student.ethz.ch> writes:\n> > \n> > > \n> > > I posted the script below on IRC the other week[1] in reply to someone\n> > > looking for a way to do this for 'meld'.\n> > ...\n> \n> Just realised I never posted my solution. This works great for me, I wouldn't do \n> without it:\n> http://blog.codefarm.co.nz/2009/08/git-diff-and-difftool-open-all-files.html\n\nThanks.  We should add git difftool --all, what do you think?\n\nDo you have any thoughts about difftool's defaults?\nI've always kind of felt that --no-prompt was a possible candidate...\n\n-- \n\t\tDavid\n"}]}