compare dates of variants or sidecar files

If you are experiencing problems with "Everything", post here for assistance.
Post Reply
flubber
Posts: 11
Joined: Mon Nov 07, 2022 2:59 pm

compare dates of variants or sidecar files

Post by flubber »

I have a number of pairs like this:

path\filename.tif
path\variants\filename.jpg

I need to find all path\variants\filename.jpg with date modified older then date modified of path\filename.tif

Any ideas how to do this?

Thanks for reading, flubber
Last edited by flubber on Mon Feb 20, 2023 8:57 am, edited 4 times in total.
void
Developer
Posts: 16749
Joined: Fri Oct 16, 2009 11:31 pm

Re: compare dates of variants or sidecar files

Post by void »

Can't be done at the moment, sorry.

I will consider an option to do this.
raccoon
Posts: 1017
Joined: Thu Oct 18, 2018 1:24 am

Re: compare dates of variants or sidecar files

Post by raccoon »

In Everything 1.5, you could do something like:

m:\path\ files: addcol:stem dupe:stem sort:dm

stem = filename without extension.
the above search will limit results to just the files in m:\path\ (and below), sort the results by the date-modified, adds the column "stem", and then shows only results where 2 or more files have the same (duplicate) stem. But it won't make sure at least one of the results comes from \variants\, or limit results to specific order of date modified.
Last edited by void on Mon Feb 20, 2023 7:16 am, edited 2 times in total.
Reason: fixed sort: call
void
Developer
Posts: 16749
Joined: Fri Oct 16, 2009 11:31 pm

Re: compare dates of variants or sidecar files

Post by void »

The following Everything 1.5 search will list path\variants\filename.jpg files where a path\filename.tif exists:

regex:^(.*)\\[^\\]*\\([^\\]*)\.jpg$ fileexists:\1\\\2.tif



fileexists:



Is the variants subfolder name always the same?
-If so, please try the following search:

regex:^(.*)\\[^\\]*\\([^\\]*)\.jpg$ fileexists:\1\\\2.tif | regex:^(.*)\\([^\\]*)\.tif$ fileexists:\1\\variants\\\2.jpg

This will list both the tif and jpg files which might be helpful.
flubber
Posts: 11
Joined: Mon Nov 07, 2022 2:59 pm

Re: compare dates of variants or sidecar files

Post by flubber »

Thank you for your attention, I appreciate it.

Yes, "\variants\" is always the same string, only path and filename stem vary.
I was already trialling:

ext:tif regex:^(.*)\.[^.]*$ !fileexists:\variants\\\1.jpg

to find missing variants. This works for me because all filename stems are unique.

I'm looking for a way to compare the data time modified of the file pairs and list only .jpg files in "\variants\" older then the date time modified of the .tif file. (I've modified my request to emphasise this.)
flubber
Posts: 11
Joined: Mon Nov 07, 2022 2:59 pm

Re: compare dates of variants or sidecar files

Post by flubber »

void wrote: Mon Feb 20, 2023 6:42 am Can't be done at the moment, sorry.

I will consider an option to do this.
OK, good to now. So I need to grab all .tif files, then grab the matching .jpg and compare their dates in a loop. Hmm, pretty lengthy.

Anyway, thanks for your lightning fast response, flubber

[Edit]
I think I found something better. Because the program modifying the .tif files will always deletes all ADS streams (it creates new .tif file and deletes the old .tiff file when writing), I plan to set an ADS name when updating the .jpg variant. The function for this is pretty simple in Everything! Something like:

Code: Select all

ext:tif !ads-names:variant_is_up_to_date
All files listed will need to be processed.

Any comments welcome, flubber
Post Reply