How to compare 2 Pages documents?
Here is how to proceed. The receipe isn't as simple as I thought.


From Pages export files to plain text:

File &gt; Export &gt; Plain Text...

so as to get 2 files: file.1.txt, file.2.txt.
Open both files with vi and apply the following command:

:%s,⌃+V⌃+M,⌃+V⌃+M,g

this command contains twice the sequence control+V, control+M which is the way to enter the raw return character. The strange effect of this command is to replace any return character (0x0d) with a standard newline character (0x0a) everywhere (g = global). Then the 2 files are now splitted in different lines and it becomes useful to compare them with any Unix text tool.
Change the 2 files encoding:

:set fileencoding=utf-8

so as to encode them as text files (and not binary files as they were exported from Pages).
Save the two files and quit vi:

:wq
Run the standard diff command to compare the 2 text files:

diff file.1.txt file.2.txt