Use Unix diff from console
While we invest lots of efforts improving our built-in diff, semantic diff and the graphical merge tools, there are times where you really need to run a diff in a terminal.
![](https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgsU6ryL5dKXgImTVdrSkgjEHy2NRgkjfK0r9898Rx6a1mSrSrDlupzY-xIuxhTo5VRafRKMJ3ekSKyGdDerdf7COGKKgYdB49yPAv3YAfh3e8GQo-QGXHBRtZov0X5kfBBYVd7iw/s1600/difffromconsole.png)
Setup your diff tool editing client.conf
All you need to do is to edit your client.conf
as follows:
![](https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhEJhIEPoeUjEL35y0rK3rYV6WHReSqAREmrb6TgQfo2U0eSqeH7sJXIzGHv02ntt1nGi-S2HpY64VsWrvRIuLRN7tpxwLBTXz40DDx8z4LCKg5V9-gYT3u1ees3hw_gTlz3MrO4A/s1600/configure-diff-tool.png)
In this case I set up the Unix diff on my Fedora, but of course you could be using sdiff or any other.
Use a separate client.conf for specific purposes
You can simply edit client.conf
and modify the diff.
But, if you want to use a different diff for CLI than GUI, then probably you'll be better served by having 2 different client.conf
files.
In my case, note I used the following:
cm diff the_file -clientconf=/home/pablo/.plastic4/client.conf.txtdiff
client.conf.txtdiff
is the modified client.conf
where I setup the command line diff.
Conclusion
Nothing really new under the sun here, just remind you that while we don't ship a console-based diff tool, it takes 1 minute to configure one.
0 comentarios: