Synchronize directories: How to compare the files content?
Moderators: Hacker, petermad, Stefan2, white
Synchronize directories: How to compare the files content?
Hello everyone,
I am new at Total Commander and I'd really need your help on something I'm trying to do.
I have two different directories, A and B. Each contains the same number of files and the files have the same name from one directory to the other. For example, if I have "Apple", "Orange" and "Tomato" in A, I'll have "Apple", "Orange" and "Tomato" in B. The difference is that the files have a more recent date in the directory A than in B. Some files have a different content from A to B, but not all.
What I need to do: Compare the content of the files in A and B. Replace, only for the files that have a difference of content, the files in B by the files in A.
The functions in the "Synchronize directories" section don't allow me to do this. Indeed, if I synchronize "by content", then it takes all the new files in A and copies them in B. If I synchronize by content and without regard for the date, it doesn't copy the files that changed content, it just writes the sign unequal.
Thank you in advance for your help!
I am new at Total Commander and I'd really need your help on something I'm trying to do.
I have two different directories, A and B. Each contains the same number of files and the files have the same name from one directory to the other. For example, if I have "Apple", "Orange" and "Tomato" in A, I'll have "Apple", "Orange" and "Tomato" in B. The difference is that the files have a more recent date in the directory A than in B. Some files have a different content from A to B, but not all.
What I need to do: Compare the content of the files in A and B. Replace, only for the files that have a difference of content, the files in B by the files in A.
The functions in the "Synchronize directories" section don't allow me to do this. Indeed, if I synchronize "by content", then it takes all the new files in A and copies them in B. If I synchronize by content and without regard for the date, it doesn't copy the files that changed content, it just writes the sign unequal.
Thank you in advance for your help!
Hi,
Thank you for your reply. I know I can change the unequal sign into something else, but I wish to avoid that because my directories are huge and it would be very long to change these signs manually.
Is there a way to change the parameters of the TC so as to never display the unequal sign and replace it by another sign?
Or is there a way to do what I want to do (as explained in my first post) in another way?
Thank you
Thank you for your reply. I know I can change the unequal sign into something else, but I wish to avoid that because my directories are huge and it would be very long to change these signs manually.
Is there a way to change the parameters of the TC so as to never display the unequal sign and replace it by another sign?
Or is there a way to do what I want to do (as explained in my first post) in another way?
Thank you
It may be completely useless for you... I have hundreds of files with one diff (i know what it is) and i need the files with 2 or more.Horst.Epp wrote:No, and it would be completely uselessjcerdeno wrote:Is it possible to filter the result of the files which has 2 or more differencies? I mean, i do not want to see the files which has just one.
Thanks a lot,
because one difference can also be a large block of lines.
2jcerdeno
How do you define two differences? Two different characters (on the same line)? Two different lines? Two different blocks? What about a mix of those, e.g. two or more different characters on two different lines? So, you see it's not that simple.
Regards
Dalai
How do you define two differences? Two different characters (on the same line)? Two different lines? Two different blocks? What about a mix of those, e.g. two or more different characters on two different lines? So, you see it's not that simple.
Regards
Dalai
#101164 Personal licence
Ryzen 5 2600, 16 GiB RAM, ASUS Prime X370-A, Win7 x64
Plugins: Services2, Startups, CertificateInfo, SignatureInfo, LineBreakInfo - Download-Mirror
Ryzen 5 2600, 16 GiB RAM, ASUS Prime X370-A, Win7 x64
Plugins: Services2, Startups, CertificateInfo, SignatureInfo, LineBreakInfo - Download-Mirror
In this case two different lines, I do not think is simple, I just answered if it is possible than when you synchronize directories, it is possible to filter the one which the "1 difference show"Dalai wrote:2jcerdeno
How do you define two differences? Two different characters (on the same line)? Two different lines? Two different blocks? What about a mix of those, e.g. two or more different characters on two different lines? So, you see it's not that simple.
Regards
Dalai