bug-diffutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bug-diffutils] Wishlist: Special treetment for symlinks and special fil


From: kubuntu-user
Subject: [bug-diffutils] Wishlist: Special treetment for symlinks and special files
Date: Thu, 27 Jan 2011 22:02:10 +0100 (CET)

To make diff more versatile, I suggest the following improvement:

- Symlinks should be compared by readlink instead of comparing the target files
- Special files such as device files should be compared by checking the major / 
minor number 
- Fifos ... ?
- Have I forgotten something ? 
 
Yes, I know, that this can not be used for creating patches, but diff is not 
only used for creating patches. ;-) 
 
The special handling could be optional, activated by command line switches. 
 
Use case: 
 
As a person still learning to work with GNU/Linux, I sometimes create a clone 
copy of my system partition on another partition before doing large 
configuraiton changes in order to have a bootable backup system in the old 
state. 
 After copying (I always do this using a live CD), I would like to verify the 
copied data using diff. Yes, I already experienced a few turned bits during 
copying. Since that, I never copy large amounts of data without verifying 
anymore. 
 
I also would like to use diff for analyzing the differences between the 
reconfigured and the backup system, especially if the reconfiguration crashes 
it :-) 
 That's the second reason why I don't use tar for backup. 
 
And here comes the problem: 
 
All the symlinks and all the special files produce so many diff errors that it 
is really hard (if not impossible) to see the real differences. 
 The errors in the symlinks occur because I do the diff in the live system, 
too. So, every symlink that points to something starting with / is broken 
because the mount points of the / partition is something like /mnt/system1 
while in the live sysstem. Comparing symlinks via readlink just would not care 
for that. 
 
And you never can check for a changed symlink (would be especially useful for 
/etc/alternatives) or a device major/minor number. 
 
It would be extremely helpful to me to have a --no-dereference and a 
--special-files switch. 
 
Thanks and Regards ...



Disclaimer:

My e-mail provider appends advertisements to my mails.
I do not have any control about this.
Nor do I have any relations with the companies or products in the 
advertisements.
Nor do I earn any money with it.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]