diff is a shell command to find differences between two files. It is common on all *nix based systems

learn more… | top users | synonyms

0
votes
0answers
10 views

How to capture diff output from find command exec?

I am using Ubuntu (Precise 12.04) I am trying to write some bash script to see if file is changed via awk replace by using diff command. I did a test with the following: #! /bin/bash diff fileA.htm ...
0
votes
0answers
33 views

Incremental Backups of ntfsclone Images

I am attempting to make compressed incremental backups of a Windows partition using ntfsclone on Linux. Currently, I am making full ntfsclone images using something like the following command: sudo ...
0
votes
4answers
1k views

What do these instructions mean in plain English?

I know it's for the linux program patch, but if I try to use it, I get the following error: missing header for unified diff at line 4 of patch malformed patch at line 5: quit Instead, I'd like to ...
2
votes
1answer
29 views

Diffing an entire hard drive, available tools?

There's an existing question similar to this that didn't get answered in the proper context (a massive volume of data to compare) at all, so I'm trying again here. I'm using SuperDuper to maintain a ...
0
votes
1answer
12 views

Recursively compare file identities in Windows environment using only standard Windows commandline tools

I want to ensure that deep directories of files are identical after copying. I've read this answer: http://superuser.com/a/414216/214579 However, neither fc or comp offer recursion. How would one ...
20
votes
7answers
30k views

Binary Diff Tools On Windows

I have two different binary files, and I want to compare their difference. Is there a free GUI based binary diff tool that is available on Windows?
0
votes
0answers
13 views

Is there a diff-like tool that searches the directory for existence of the file or folder?

In an attempt to de-duplicate the data on my system, I've used tools such as Gemini for finding duplicate files across directories and diff tools like Kaleidescope for understanding how the ...
7
votes
5answers
5k views

How can I compare two directories, one being a remote directory?

I want to compare two directories, one is local and the other is on another machine. How can I do that? Can I do it with diff?
67
votes
7answers
103k views

How do I compare binary files in Linux?

I need to compare two binary files and get the output in the form <fileoffset-hex> <file1-byte-hex> <file2-byte-hex> for every different byte. So if file1.bin is 00 90 00 11 in binary ...
7
votes
3answers
4k views

Binary diff/patch for large files on linux?

I've got two partition images (A and B) and want to use them to create a patch that I can apply on A on another computer in order to get the new B image without flooding the network. I have the ...
2
votes
5answers
7k views

Difftool for Ubuntu like OS X's Opendiff

What is the best difftool for Git repos like OS X's Opendiff?
3
votes
2answers
104 views

How do I compare two folders recursively and generate a list of files and folders that are different?

tl;dr and an example I'm looking for a way to compare two folders recursively and output the relative paths all files (and folders) that are different (by size or by timestamp, à la rsync). For ...
8
votes
3answers
1k views

How to ignore whitespace in Kaleidoscope (diff tool)?

In Kaleidoscope, how do I configure it to ignore whitespaces?
0
votes
2answers
472 views

Diff to actually totally ignore whitespace

I am looking for an application that will diff two files, and actually ignore all whitespace, so for example: class foo { bar spaz } is equally equivilant to class foo{bar spaz} or, as ...
1
vote
0answers
20 views

OSX Terminal: FTP upload only if file size different

I am currently using FileZilla to backup my Documents. The manual procedure for this is as follows: Sign in to FTP using username and password Open Documents folder on FTP site Drag documents from ...
0
votes
1answer
12 views

Diff content of a website recursively

I have a lot of tools I'm using and want to be able to monitor their changes through their documentation. An example would be Vagrant Documentation - https://docs.vagrantup.com/v2/. I want a solution ...
2
votes
2answers
264 views

How to compare two files for non-printing characters

To share a configuration file between two computers, I emailed the file to myself via my gmail account. When I loaded the conf on the second computer, the program had trouble reading every line. ...
0
votes
2answers
32 views

compare two directory trees

I have two music libraries, one a newer version than the other. I would like to compare them to figure which files I need to copy from new music tree to old. I have tried diff --brief -r ...
0
votes
2answers
35 views

Merge two text files, with differences highlighted

I have two text files, which are almost the same except for some changes on a few lines. I would like to merge these two files into a single text file, with differences highlighted, so that I can then ...
2
votes
3answers
198 views

Compare file system properties/attributes of two files

There are many methods that can be used to compare the data of two files. That is not what I'm interested in here. How can I easily compare or "perform a diff" of what could be called (perhaps you ...
0
votes
1answer
12 views

How to group “Only in” lines in diff at the beginning of the output

I did: diff -r directory1/ directory2/ Some files are different, and some files were only in one tree or the other, creating several Only in ... lines. How do I group these lines at the beginning ...
0
votes
0answers
131 views

Kdiff3 show conflict even that files have equal text and are binary equals

Like in title. Kdiff3 info dialogue shows that ( i do 2 way merge): Total number of conflicts: 0 Nr of automatically solved conflicts: 0 Nr of unsolved conflicts: 0 kdiff3 files a and b have equal ...
1
vote
1answer
325 views

Show git diff HEAD~1 of file not touched in recent commits

In Git, to see the differences with a previous commit I run this: git diff HEAD~1 To see the commits related with a single file I would run this: git log --oneline file But if I run the ...
17
votes
6answers
13k views

How can I diff two XML files?

On Linux, how could I generate a diff between two XML files? Ideally, I would like to be able configure it to some things strict, or loosen some things, like whitespace, or attribute order. I'll ...
0
votes
1answer
27 views

Dynamic diff of one file

I am trying to diff one file over time using process substitution in bash. diff <(cat /path/to/file | sort; sleep 20) <(cat /path/to/file) I also tried: diff <(cat /path/to/file | sort ...
13
votes
3answers
2k views

How can I enable colored output for OSX diff?

I need to diff two files (not two versions of the same file, they are however tracked by git, but that is unrelated) and I would like some colored output, how can I achieve that? $ diff file_1 file_2 ...
0
votes
0answers
16 views

Colorize only the changes and not the complete line in diff

I have to very similar files which usually only differ in the capitalization. Currently I'm using the default diff but seeing the actual difference can be hard. For example I compare files only ...
0
votes
0answers
17 views

Software for creating DB alter script that ONLY uses DDL scripts

I am looking for a software which can compare two databases by ONLY using DDL script (i.e. I dont want to create a schema but rather do it on the fly). Is this possible ? Any ideas ?
1
vote
2answers
30 views

Find two newest change files and compare them

I have a script that wgets a .txt file and datifies the names. I'd like to diff the changes between the newest & next-to-newest file. This is how I am able to select them: ls -t -l | awk ...
1
vote
1answer
37 views

recursive diff of files case-insensitive

How do I run a recursive diff when the filenames are the same but have different cases? For instance: ./Root/Directory/FileName.txt ./Branch/directory/filename.txt diff -r -i Root Branch only ...
0
votes
1answer
19 views

How can I `diff` two Accumulo tables?

If I wanted to compare two similar Accumulo tables and highlight their differences, how could I do this? My first thought is creating database dumps and running Unix diff over the files, but that ...
0
votes
0answers
50 views

Three way binary comparison for savegame hacking

Basically, I'm trying to compare a bunch of savegames to find where some values are stored. First of all, it's a rogue-like interpreted in WinGlulxe. I'm dealing with almost 100% binary save files ...
0
votes
0answers
78 views

Alternative to diff with progress for massive directory compare?

I just rsync-ed 2,000,000 files (3TB) from one RAID to another. I want to make sure my data is intact. rsync -c takes a really long time. diff doesn't show me what it's doing. Is there an ...
1
vote
1answer
26 views

Attempting to combine diff command and display last modified between dupes

I am attempting to do something a bit unique, and cannot find the right terminal command line to use. I am attempting to essentially solve for the following problem: I have two volumes of data that ...
0
votes
1answer
703 views

How can I diff binary files in git?

I assume I need to set up a difftool. What difftools work? How do you put the parameters in?
3
votes
4answers
2k views

Is there a diff utility that allows you to exclude columns?

For example, I have a text file, each line is a long string. I want to exclude 2 "segments" of this string, say columns 1-7 and 20-22. So the bottom 2 lines below would be a match: ...
0
votes
1answer
42 views

How am I supposed to use diff in this situation?

I recently asked a Google Groups forum for help with setting up a Vagrant/Chef/Django VM thingamajigger, and I received the following help: The fabfile.py had some errors for me. After I fixed ...
0
votes
1answer
50 views

How to make redirected input count as command output

I have a simple C console program that takes some keyboard input and outputs prompts and calculations. I also have two text files: a file with input for the program, and a file that contains the ...
2
votes
4answers
2k views

Similarity and/or Diff of two ODT documents (Linux)

I have two ODT documents, they have very close contents, I want to compare them to see how similar they are. The best would be to have a similarity percentage, if not possible, an alternative would ...
2
votes
1answer
292 views

Binary diff tool which would work the same way as diff(1) tool

Do you know Unix/Linux diff(1) tool works? It shows which lines were added and removed between 2 text files, and shows it in the human-readable form. I need the same kind of tool for binary files - ...
12
votes
3answers
7k views

How to diff large files on Linux

I'm getting a diff: memory exhausted error when trying to diff two 27 GB files that are largely similar on a Linux box with CentOS 5 and 4 GB of RAM. This is a known problem, it seems. I would expect ...
2
votes
2answers
187 views

Comparing 2 (or 3 Files If Possible) “Line By Line”

I want to find out the differences of 2 (or 3 files if possible) line by line. Diff utils can do this, however it gives inaccurate results. Because, 2 files have exact number of lines which is "134". ...
3
votes
1answer
392 views

Sorting XML files so that differences can then be found

I need to compare two XML files, each of which is about 13,000 lines long. Sadly the code that generates these files doesn't generate the data in the same order each time (the data comes from a ...
1
vote
0answers
146 views

StatSVN generated XML is slightly out of date

There are no StatSVN questions on superuser, but why not start? ;-) Here's my problem... I generate a log from subversion with: svn log -v --xml > log.xml The latest revision that shows up in ...
0
votes
2answers
46 views

What is the right tool to diff filecontents of a directory in OSX?

I know that I can use Git for some cases, but I still believe that there exists a simpler solution by default. Does there exists any tools by default in the newest OSX for the diff of filecontents in ...
1
vote
2answers
200 views

diff and patch tool

I'm trying to generate patches for a bunch of files I changed. I'm using Meld which does a great job of diff’ing the files in a nice visual manor, then it allows me to save and generate a patch file ...
0
votes
2answers
223 views

How to compare content of two files?

I got a mission to compare the content of hundreds of pair files. I have to quickly compare each pair and to provide an answer if that pair is equal (in content) or not. The files could be text or ...
16
votes
4answers
9k views

vimdiff: Jump to next difference inside line?

vimdiff is very handy for comparing files. However, I often use it on files with long lines and relatively few differences inside the lines. vimdiff will correctly highlight differences inside a line ...
3
votes
3answers
700 views

Using diff on a long one line file

I have a file that has only one line. Its size is about 20,000 bytes. The file has been modified, and I wanted to know where. I thought using diff, but it shows me the complete line, because it ...
0
votes
0answers
15 views

Visualizing multiple word-based changes among many text files

I've written a piece of fiction with GitHub. I'm curious to see how my writing adapted over time. Did I keep eliminating then re-adding a word? Did some lines remain unchanged? Which paragraphs ...