Diff file viewer? - version-control

I'm looking for a tool that displays diff files (generated from mercurial, in my case) in some convinient manner. For example, the way bugzilla displays diff patches. Just to be clear, I'm not looking for something that compares/merges files, I already got the diff, just want a convinient way to inspect it.
I couldn't find anything that does that (diff syntax highlighters were the closest thing I got), anyone knows of anything?

Have you tried meld? (it works only in UNIX though..)

I would look into the following Atlassian product 'FishEye' http://www.atlassian.com/software/fisheye/
This allows you a lot of control over your version control system and code views/diffs/code reporting/visualisation etc.

I really like Beyond Compare and Araxis Merge (especially Araxis).

I had the same question -- basically a good syntax highlighter for diff output. I wanted something lightweight and free.
Now I'm using sdif and cdif together.
sdif does the syntax highlighting you want
cdif does word context diffs, so that on a modified line the words that have changed are highlighted differently

As #tomahawk suggested, if you point FishEye at your Hg repository you'll be able to diff between revision of a file, and view a changeset as a diff.
If you want to look at arbitrary patch files, you could buy Atlassian's Crucible, which allows you to create a code review by uploading a patch, which you can then view as a nice diff (and comment on collaboratively, but that is probably not of interest to you). A 5 user Crucible licence costs $10.
(Disclosure: I'm a Crucible developer at Atlassian)

Related

Graphical diff for darcs

I don't feel very comfortable seeing the darcs changes in plain text format, so I've been looking for a tool to display a nice side-by-side comparison of the changes.
For the whatsnew I can just use meld, but when I need see the changes already recorded it does not work as easily. I've read that diffuse allows to compare different revisions, but I cannot get it to work.
I've tried
diffuse -r HEAD^1 -r HEAD^2 myfile.py
but it fails (I think that revision naming is specific to git), so does somebody know how to see the latest changes in darcs?
Suggestions for other tool that does the work (and does not require to set up a web server preferably) are welcome.
in fact you should write something like:
darcs diff --diff-command="diffuse %1 %2" myfile.txt
It works with ECMerge (the tool I work on), it should work seamlessly with diffuse. Darcs will call diffuse with temporary files as necessary (to compare the files from the repository). By the way, ECMerge can dig in Darcs configurations with its browser UI.
EDITED:
to diff tags or patches in the repository, use --from-tag= or --from-patch= and --to-tag= or --to-patch= notation. You should be able to do what you want, however note that from-patch means "from before patch" and --to-patch means "up to after patch". it was not really obvious for me...
(to know the last of changes use darcs changes)
I do not know how to integrate with darcs, but KDiff3 is a wonderful graphical diff/merge application available both for linux, macos and windows.

System for automatically logging exact file code changes by line item

Does anyone know of a software or system for automatically tracking and logging exact line code changes into a log file?
For example, lets say I edit 7 files on Jan 16th, and I add and modify several lines of code in each file.
Is there a software or tool of any kind that would automagically know what edits I made, what was changed, and log the details in date order line-item file?
I am guessing something exists like this, but I cannot find out what I should be searching for. I looked at SVN and some other similar, but didn't get these capabilities from the descriptions I read.
There's nothing that would automagically know this. This sort of information is easy to come by as a side-effect of using virtually any version control system though. It sounds like you're not using any VCS, you should start doing so now. SVN is a good option to start with.

Are there any apps that save backup versions of a file with one click (save, commit, etc) live while editing?

Just something that will save changes automatically, while i'm editing say in gedit, or notepad plus plus, or even windows text editor, etc.
I can't seem to find exactly what I'm looking for and svn, bzr, and Git are too complicated. One should be able to start a new project, start writing code, and that's it!
So... I'm going to create a whole new version control system that will be more amazing and simple than all the rest! Unless something already exists? Whether it be online, or a local install, whatevs.
EDIT: Ok, the above paragraph was a bit absurd now that I read it much later. I use Git now, and Git is awesome.
Many text editors will create a backup copy of the prior version when you do a save.
Of course, this is pitiful compared to an actual version control system. You should know that many VCS integrate with editors so commits are very simple quick commands.
The minor time it takes to create a repository is insignificant compared to the time it will save you during the project.
Frankly, this sounds like an argument from ignorance.
I found this nice little Gedit plugin: http://nerdblog.pl/2009/06/01/save-and-commit-to-git-plugin-for-gedit-2-26ave/

Eclipse diff for large file shows incorrect differences

I am not sure if anybody has experienced this.
I am working with a very large file having 7000 lines of code.
I made a lot of changes and when i compared the file with the repository version, it showed me incorrect differences.
I guess the diff algorithm buffers only limited number of lines ahead/behind for searching the current line, and on failing to find that, it simply shows diff with current line in new file.
One such snapshot > http://picasaweb.google.com/lh/photo/ENwZ4gqXxiCF3SWqVnVAqA?feat=directlink
If anybody knows any workaround, please let me know.
Thanks
Easy workaround - use another diff tool. I'm serious. I wouldn't waste time splitting up my files, or wondering how to get it to work with Eclipse's diff tool if there's some known issue with really big files.
I recommend Beyond Compare 3. I say this having used many different diff tools. It's not free, but it's worth it. In the rare chance that it gets confused, it allows you to with a couple of clicks realign any areas that it got confused on. I have used it with some pretty large files, and it rocks.
If you're concerned about Eclipse integration, there's even a plugin, BeyondCVS, that allows you to launch your Beyond Compare diffing from the Eclipse right click 'Compare' menus. Its name is kind of misleading though, as it doesn't appear to be related to CVS.
If you need something free, try one of these diff tools instead:
WinMerge
SourceGear DiffMerge
What version of eclipse are you using? And what edition? (Java? CDT? ...)
Depending on those data, it could make a difference, since files with several thousand lines are known to be a problem for the diff algorithm.
See this thread for illustration.
And do check, as mentioned in the same thread, your error log to check if any particular message could help you to pinpoint the cause of the failed diff.

Diff/Compare Tool That Lets Me Write Comments On Differing Lines

I'm looking for a diff/compare tool that shows differing lines from two text files, and gives me a space to comment on those files. Ideally this application would have three panes, pane one would be file A, pane two would file B and pane three would be a comment I can enter to on why the files are different.
We're going to be using this diff tool to compare test and production environments. Sometimes it'll be justifiable that the two files are different but we need to have a space to explain why. I'd rather not write those comments in the files themselves.
I've used TortosieMerge, WinDiff and Beyond Compare. I like beyond compare the most because it lets me see the whole file, just the differing lines or the differing lines in context.
Tools that sit inside Visual Studio or eclipse are fine too.
It sounds to me like you might want to use a code review tool for this (even if you're not really performing code reviews). They record diffs in a database and allow comments on those diffs.
A couple free ones are:
CodeStriker - I've used this and it works pretty well, but required more tweaking and mucking around in Perl that I'd have liked (that was a while ago, though)
Review Board - never used this, but it sure looks nice. I'm trying to get it installed at my current place of work.
I would like to suggest a high-efficiency software CodeGen to you. It's not only include TextCompare tools, but another Codec/Database tools is supported as well.
For more detail, please kindly access the Github repository.
https://github.com/work7z/CodeGen