Friday, October 21, 2011

Use Meld as a GUI for Git diff

To diff a directory in the workspace with Git's staging area

06:24 PM ~/app_0515 $ git difftool -t meld app/views

Viewing: 'app/views/participants/index.html.erb'
Hit return to launch 'meld':

Viewing: 'app/views/sent_messages/index.html.erb'
Hit return to launch 'meld':

Viewing: 'app/views/sent_messages/show.html.erb'
Hit return to launch 'meld':


To diff between the master branch and a remote branch

07:37 PM ~/app_0515 $ git difftool -t meld home/master master

Viewing: 'app/controllers/participants_controller.rb'
Hit return to launch 'meld':


Viewing: 'app/helpers/application_helper.rb'
Hit return to launch 'meld':
Viewing: 'app/models/participant.rb'
Hit return to launch 'meld':

Viewing: 'app/views/participants/index.html.erb'
Hit return to launch 'meld':

Viewing: 'app/views/sent_messages/index.html.erb'
Hit return to launch 'meld':

Viewing: 'app/views/sent_messages/show.html.erb'
Hit return to launch 'meld':



To diff between the repository and the staging area:
12:42 PM ~/lib/rubygsm $ git difftool -t meld HEAD core.rb

Viewing: 'lib/rubygsm/core.rb'
Hit return to launch 'meld':




No comments:

Post a Comment