DiffMerge with command line arguments on OS X
Moderator: SourceGear
-
- Posts: 2
- Joined: Sun Nov 04, 2007 6:50 am
- Location: Scotland
- Contact:
DiffMerge with command line arguments on OS X
Hi.
I am writing a GUI client for the Bazaar version control system. It is a cross platform app, using wxWidgets. I am currently thinking about providing the option of using external dff/merge tools, and would like to provide support for SourceGear's DiffMerge.
I am trying to figure out how to tell DiffMerge to diff two ffrom the command line in OS X at the moment.
I've tried:
open -a /Applications/DiffMerge.app file1.txt file2.txt
This approach works with TextEdit.
Can someone point me in the right direction for opening DiffMerge with two or three files from the OS X terminal?
Thanks,
Sandy
I am writing a GUI client for the Bazaar version control system. It is a cross platform app, using wxWidgets. I am currently thinking about providing the option of using external dff/merge tools, and would like to provide support for SourceGear's DiffMerge.
I am trying to figure out how to tell DiffMerge to diff two ffrom the command line in OS X at the moment.
I've tried:
open -a /Applications/DiffMerge.app file1.txt file2.txt
This approach works with TextEdit.
Can someone point me in the right direction for opening DiffMerge with two or three files from the OS X terminal?
Thanks,
Sandy
-
- Posts: 534
- Joined: Tue Jun 05, 2007 11:37 am
- Location: SourceGear
- Contact:
OPEN on the Mac behaves somewhat differently than expected.
From my testing, I couldn't get the Mac's OPEN command to behave as expected.
In the 3.1.0 release, I included a "CommandLine/diffmerge.sh" shell script that should do what you want.
Hope this helps,
j
In the 3.1.0 release, I included a "CommandLine/diffmerge.sh" shell script that should do what you want.
Hope this helps,
j
-
- Posts: 2
- Joined: Sun Nov 04, 2007 6:50 am
- Location: Scotland
- Contact:
-
- Posts: 1
- Joined: Thu Nov 01, 2012 5:07 am
Re: DiffMerge with command line arguments on OS X
Can you add a preference that would run this command?
ln -s /Applications/DiffMerge.app/Contents/Resources/diffmerge.sh /usr/local/bin/diffmerge
Would make life easier for the users
ln -s /Applications/DiffMerge.app/Contents/Resources/diffmerge.sh /usr/local/bin/diffmerge
Would make life easier for the users
-
- Posts: 534
- Joined: Tue Jun 05, 2007 11:37 am
- Location: SourceGear
- Contact:
Re: DiffMerge with command line arguments on OS X
I'll log that. Thanks!
jeff
jeff
Re: DiffMerge with command line arguments on OS X
Hi. This script worked great for setting up DiffMerge as the difftool for git in OSX.
I've seen in another thread where it was mentioned SourceGear doesn't support specifying a folder diff from the command line, with a reason given that this is primarily a GUI tool.
And that's how I want to use it, as my GUI diff tool, but it would be *so* nice to be able to specify a folder diff for git. I'm not interested in scripting anything here -- just to launch with a folder diff when I run git difftool.
I know time is limited and all, but wanted to register my preferences.
Thanks for DiffMerge -- this is my favorite GUI diff tool.
Scott
I've seen in another thread where it was mentioned SourceGear doesn't support specifying a folder diff from the command line, with a reason given that this is primarily a GUI tool.
And that's how I want to use it, as my GUI diff tool, but it would be *so* nice to be able to specify a folder diff for git. I'm not interested in scripting anything here -- just to launch with a folder diff when I run git difftool.
I know time is limited and all, but wanted to register my preferences.
Thanks for DiffMerge -- this is my favorite GUI diff tool.
Scott
-
- Posts: 534
- Joined: Tue Jun 05, 2007 11:37 am
- Location: SourceGear
- Contact:
Re: DiffMerge with command line arguments on OS X
Thanks!
we do support taking folder arguments on the command line and
will open a gui window with the 2 folders. what we don't support
is taking folders on the command line and having it print the
list of changed files to the console/stdout.
i haven't looked at git's config settings recently, but it sounds like
you might have a config setting problem or that they have a different
config setting for folder diffing. again, i'm not sure, but you might
give that a try.
jeff
we do support taking folder arguments on the command line and
will open a gui window with the 2 folders. what we don't support
is taking folders on the command line and having it print the
list of changed files to the console/stdout.
i haven't looked at git's config settings recently, but it sounds like
you might have a config setting problem or that they have a different
config setting for folder diffing. again, i'm not sure, but you might
give that a try.
jeff
Re: DiffMerge with command line arguments on OS X
Ah! And so it does. I should have tried running directly with diffmerge.sh first. Thanks for your reply -- now to figure out how to make it work in difftool.
(Edited to add the how:)
git difftool --dir-diff
Works great, and now I'm in diff heaven. Thanks again!
Scott
(Edited to add the how:)
git difftool --dir-diff
Works great, and now I'm in diff heaven. Thanks again!
Scott