[suggestion] compare content: [x] ignore time items

Here you can propose new features, make suggestions etc.

Moderators: white, Hacker, petermad, Stefan2

Post Reply
horizon
Junior Member
Junior Member
Posts: 32
Joined: 2006-11-23, 11:32 UTC

[suggestion] compare content: [x] ignore time items

Post by *horizon »

Hi!
I have started to use you content comparator and I am very nicely surprised... but option to ignore different time items would be helpful...

Just for instace these parts of the log for same action from different servers...

Code: Select all

Action ended 23:16:58: BuildSymEventCAData.8728755E_EBB5_45CB_BF13_FE75340D7B4E. Return value 1. 
Action start 23:16:58: CheckInstallPath. 
Action ended 23:16:58: CheckInstallPath. Return value 1. 
Action start 23:16:58: SetARPINSTALLLOCATION. 
Action ended 23:16:58: SetARPINSTALLLOCATION. Return value 1. 
Action start 23:16:58: SetODBCFolders. 
Action ended 23:16:58: SetODBCFolders. Return value 1. 
and

Code: Select all

Action ended 0:25:56: BuildSymEventCAData.8728755E_EBB5_45CB_BF13_FE75340D7B4E. Return value 1. 
Action start 0:25:56: CheckInstallPath. 
Action ended 0:25:56: CheckInstallPath. Return value 1. 
Action start 0:25:56: SetARPINSTALLLOCATION. 
Action ended 0:25:56: SetARPINSTALLLOCATION. Return value 1. 
Action start 0:25:56: SetODBCFolders. 
Action ended 0:25:56: SetODBCFolders. Return value 1. 
...could be considered as same. (as the only difference are time items). thanks and best regads
User avatar
Flint
Power Member
Power Member
Posts: 3487
Joined: 2003-10-27, 09:25 UTC
Location: Antalya, Turkey
Contact:

Post by *Flint »

horizon
Maybe this will help:

Code: Select all

23.05.06  Added: Compare by content: New experimental feature to skip the first x characters in a file (e.g. the date/time in a log file): wincmd.ini [Configuration] CompareSkipFirstL=x1 CompareSkipFirstR=x2    (left/right separately)
© History.txt :)
Flint's Homepage: Full TC Russification Package, VirtualDisk, NTFS Links, NoClose Replacer, and other stuff!
 
Using TC 10.52 / Win10 x64
User avatar
menet
Member
Member
Posts: 199
Joined: 2005-04-21, 12:27 UTC
Location: Paris, France

Post by *menet »

I have tried it just for fun adding in wincmd.ini : 8)
CompareSkipFirstL=8
CompareSkipFirstR=0

I have edited a HISTORY.TXT of total commander and just changed 1 date in a line.

After the add of these 2 variables, TC comparison of the old and new file marks all the lines. Only the empty lines are not marked in red. :(

Where is the error in the compare tool new option or I have bad understanding how to initialize the variables ? :?:

It should be possible to enable/disable these 2 variables to do normal comparison (back to original comparison) :idea:

Best regards :wink:
#22273 Personal licence
User avatar
Flint
Power Member
Power Member
Posts: 3487
Joined: 2003-10-27, 09:25 UTC
Location: Antalya, Turkey
Contact:

Post by *Flint »

menet wrote:I have tried it just for fun adding in wincmd.ini :
CompareSkipFirstL=8
CompareSkipFirstR=0
Why 0? In the right file you have some characters to skip too, as far as I understand...
Moreover, the first part of the line which should be skipped is not 8 characters but 21. So, for the example above you should write:
CompareSkipFirstL=21
CompareSkipFirstR=21
Flint's Homepage: Full TC Russification Package, VirtualDisk, NTFS Links, NoClose Replacer, and other stuff!
 
Using TC 10.52 / Win10 x64
User avatar
menet
Member
Member
Posts: 199
Joined: 2005-04-21, 12:27 UTC
Location: Paris, France

Post by *menet »

Hi Flint,

You have made a mistake, I made a trial with 2 HISTORY.TXT file from Total Commander (I have updated one date in one file).
I am not horizon, the creator of this topic. :!:

Then the values that I must put in wincmd.ini are : 8)
CompareSkipFirstL=8
CompareSkipFirstR=8

CompareSkipFirstL=x : is for the file in the Left panel and we will ignore the "x" first characters. (Same for the file in Right panel in CompareSkipFirstR=y)

Then now, if I compare the 2 files there is a beep because he found "0 differences found" :P


I had not well understood the way the variables works, I was thinking that the 2 files must have the same format (with same columns) but with different dates. And then the first value was to ignore the "x" first characters beginning on Left going to the right for the 2 files; the second value was to ignore the "y" first characters but beginning from the left going to the right for the 2 files. So "0" was to ignore no characters in that way. But it is not like that, that this comparison option works !

I readd my suggestion : It should be possible to enable/disable these 2 variables to do normal comparison (back to original comparison) :idea:

Best regards :wink:
#22273 Personal licence
User avatar
Valentino
Power Member
Power Member
Posts: 706
Joined: 2003-02-07, 00:21 UTC
Location: Ukraine

Post by *Valentino »

And it should be possible to make this configuration (CompareSkipFirstL, CompareSkipFirstR) in the Compare window itself without editing INI file manually back and forth for different files (usual files, different log formats).
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48077
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

This is just an _experimental_ feature, and not perfect at all yet. For example, lines which compare as identical after the ignored part are still shown as different (in red color) if they differ in the ignored part - that part is only ignored in the line by line ignore phase. The feature would need a lot of additional work, for which I just don't have the time right now.
Author of Total Commander
https://www.ghisler.com
User avatar
Flint
Power Member
Power Member
Posts: 3487
Joined: 2003-10-27, 09:25 UTC
Location: Antalya, Turkey
Contact:

Post by *Flint »

menet wrote:You have made a mistake, I made a trial with 2 HISTORY.TXT file
Oops, sorry, I have missed that when reading...
menet wrote:But it is not like that, that this comparison option works !
That's why they are called CompareSkipFirstL for Left and CompareSkipFirstR for Right. :D
Flint's Homepage: Full TC Russification Package, VirtualDisk, NTFS Links, NoClose Replacer, and other stuff!
 
Using TC 10.52 / Win10 x64
User avatar
menet
Member
Member
Posts: 199
Joined: 2005-04-21, 12:27 UTC
Location: Paris, France

Post by *menet »

Flint wrote:That's why they are called CompareSkipFirstL for Left and CompareSkipFirstR for Right. :D
But it didn't tell me, like I had said, that it was Skip in the file that is in the Left/Right panel :!:
I had understood Skip from the Left/Right of the files. 8)

Regards :wink:
#22273 Personal licence
Post Reply