Enhancement to compare time stamps on files: 'n' number of hours

Here you can propose new features, make suggestions etc.

Moderators: white, Hacker, petermad, Stefan2

Post Reply
HYPO
Junior Member
Junior Member
Posts: 13
Joined: 2020-01-16, 06:28 UTC

Enhancement to compare time stamps on files: 'n' number of hours

Post by *HYPO »

Total Commander compare files also including their timestamp. One can select to ignore an 1 hour difference to easily manage day time differences between two computers on a network.

However if files are compared on computers several time zones apart then files will appear as different, even if they are not, just because their time stamp is offset by the time zone difference. Such time stamp differences can arise due to the way/method files are synchronized in such environments.

So my suggestion is to have an "ignore this time-difference field" so that files in a two-pane copy are considered the same if the only difference between the files is a certain number of hours. Such a field would be useful in ordinary two-pane operations. And it would also be useful in the separate "Synchronize directories" panel.

The app FreeFileSync supports this but I would very much prefer to use Total Commander due to its superior user interface.

Regards
User avatar
petermad
Power Member
Power Member
Posts: 14700
Joined: 2003-02-05, 20:24 UTC
Location: Denmark
Contact:

Re: Enhancement to compare time stamps on files: 'n' number of hours

Post by *petermad »

And it would also be useful in the separate "Synchronize directories" panel.
It is actually already possible to set the hour difference when Synchronizing with an FTP-server, so maybe just an option to use the same feature in other situations.
License #524 (1994)
Danish Total Commander Translator
TC 11.03 32+64bit on Win XP 32bit & Win 7, 8.1 & 10 (22H2) 64bit, 'Everything' 1.5.0.1371a
TC 3.50b4 on Android 6 & 13
Try: TC Extended Menus | TC Languagebar | TC Dark Help | PHSM-Calendar
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48005
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: Enhancement to compare time stamps on files: 'n' number of hours

Post by *ghisler(Author) »

It's strange that you have these problems. Nowadays all Windows installations use NTFS, which stores the file timestamps in UTC (universal time). The conversion to local time only occurs when displaying the timestamps. So even if the PCs use different time zones, the timestamps of copied files should not differ when displayed locally.

Here is what I tested:
1. Copied a file from my desktop PC via SMB (Windows shared folder) to my laptop. Timestamp: 18:12 (6:12PM).
2. On the Laptop, right clicked on the date/time in the Windows taskbar
3. Choose to change Date/Time
4. Changed the time zone by one hour
5. Checked the timestamp:
- on the Laptop, it now shows 19:12
- on the Desktop via SMB, it still shows 18:12 because the time zone on the Desktop is still the same
Author of Total Commander
https://www.ghisler.com
HYPO
Junior Member
Junior Member
Posts: 13
Joined: 2020-01-16, 06:28 UTC

Re: Enhancement to compare time stamps on files: 'n' number of hours

Post by *HYPO »

Thanks for your interest in this subject.

Total Commander copies files across different time zones fine using VPN and \\<IP address>\<Something>. Say between Japan and Europe. Time shown is the same on both sides of the two panes.

However if the files are ZIP'ed locally on the Japanese location and the ZIP'ed file is then copied and then expanded on the European side then the expanded files will show a 7 hour difference ( say 10 => 17 ) in time stamp when compared in the two panes. The same time difference is seen in the ZIP file so Total Commander is consistent in its operation.

So sometimes synchronizing is simple because the time stamps are the same. And sometimes the time stamps may be offset. Depending how the file transfer was done.

Maybe the problem is within the ZIP routine ( as used by Total Commander ). But it could be easily solved by having a time offset field for file comparison.

Maybe there is already an option somewhere to handle this. But I haven't found it.

Regards
User avatar
Usher
Power Member
Power Member
Posts: 1675
Joined: 2011-03-11, 10:11 UTC

Re: Enhancement to compare time stamps on files: 'n' number of hours

Post by *Usher »

2HYPO
So you really need enhancement only for WcmZIPxx.dll.

A few words about zip: Old zip standard keeps local DOS compatibility - filenames in OEM encoding, timestamps saved without any knowledge about time zones. In newer zip version you can save filenames in Unicode, but I haven't heard any news about timestamps.

TC already can change encoding for filenames after zip opening so maybe it's possible to change time zone offset (both hours and minutes!) as well.

However, I would suggest to use newer packing formats - 7zip, rar.
Andrzej P. Wozniak
Polish subforum moderator
HYPO
Junior Member
Junior Member
Posts: 13
Joined: 2020-01-16, 06:28 UTC

Re: Enhancement to compare time stamps on files: 'n' number of hours

Post by *HYPO »

I cannot force other users to use a specific tool when copying/transferring files across time zones.

But I can see the end effect of this freedom. Some files have the same time stamp. Some files differs by some hours.

The simple solution to this problem is being able to specify a specific hour difference to ignore when copying files.

The utility FreeFileSync has this feature. But I would prefer just using Total Commander.

Regards
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48005
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: Enhancement to compare time stamps on files: 'n' number of hours

Post by *ghisler(Author) »

ZIP is a problem because it uses local time to store timestamps.
According to my research, 7z and tar/tar.gz use UTC for time stamps. You shouldn't have these problems when using one of these formats to transport your files.
Author of Total Commander
https://www.ghisler.com
anmac1789
Junior Member
Junior Member
Posts: 36
Joined: 2020-11-30, 01:33 UTC

Re: Enhancement to compare time stamps on files: 'n' number of hours

Post by *anmac1789 »

Are you saying that 7z files will adjust their date modified timestamps based on which region in the world the files are being extracted?
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48005
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: Enhancement to compare time stamps on files: 'n' number of hours

Post by *ghisler(Author) »

Yes they will!
Author of Total Commander
https://www.ghisler.com
Post Reply