photools.com Community

IMatch Bug Reports and Feature Requests => Feature Requests => Archive (Feature Requests) => Topic started by: DavidOfMA on November 25, 2014, 10:19:12 PM

Title: Call Renamer from a script
Post by: DavidOfMA on November 25, 2014, 10:19:12 PM
It would be very helpful to be able to call the Renamer from a script. I

n IMatch 3.6, I was a me to create a batch file that copied files from my SD card, called the Adobe DNG converter to convert the RAW files, started IMatch, and inside IMatch renamed the files and assigned default categories. When I came back to the computer, all that was left to do was add additional categorizing.

In IMatch 5, this single process becomes a 3-step process. I run a batch file to copy the image files and convert to DNG, then start IMatch. Then I manually run the Renamer. Then I run a script to categorize. 

Thanks for considering this request.

David
Title: Re: Call Renamer from a script
Post by: Mario on November 25, 2014, 10:24:25 PM
1. I think this was requested and discussed before. Did you check other feature requests?

2. If you run a script anyway, why don't you rename the files in your script? Everything that is done by the Renamer can also be done from a script, including rename, move, copy and categorize.
Title: Re: Call Renamer from a script
Post by: Ferdinand on November 25, 2014, 10:50:37 PM
Quote from: Mario on November 25, 2014, 10:24:25 PM
Everything that is done by the Renamer can also be done from a script, including rename, move, copy and categorize.
Are buddy files handled automatically when using the Database.RenameFile method?  (The help file does not say, and my recollection is that they weren't when using the equivalent method in 3.6.)
Title: Re: Call Renamer from a script
Post by: DavidOfMA on November 25, 2014, 10:53:12 PM
I did look for other, similar requests and didn't see them. The main problem I'm having with Imatch 5, I now remember, is there doesn't seem to be a way to trigger a rescan of my "ingestion" folder tree. In IMatch 3, I used a Basic routine written by another user to read the files, then renamed them, then categorized. All this happened serially, so I could start my batch file, go do something else, and find IMatch opened to my New Photos category ready to complete the process. So perhaps the request should instead be for a way to rescan a folder tree from within a script.
Title: Re: Call Renamer from a script
Post by: ubacher on November 25, 2014, 11:41:30 PM
QuoteSo perhaps the request should instead be for a way to rescan a folder tree from within a script.

If I recall correctly that too was requested quite some time back.  I would be a happy man if I could do this!
Title: Re: Call Renamer from a script
Post by: DavidOfMA on November 26, 2014, 04:37:04 AM
Quote from: Mario on November 25, 2014, 10:24:25 PM
2. If you run a script anyway, why don't you rename the files in your script? Everything that is done by the Renamer can also be done from a script, including rename, move, copy and categorize.

Also, for a non-programmer like me, it is much easier to modify a naming scheme in the Renamer than it would be to do so in a script. Being able to call the Renamer from the script, with a named preset as a parameter, adds that ease of renaming, copying, and moving to scripting in a way that is more accessible than it otherwise would be.
Title: Re: Call Renamer from a script
Post by: Mario on November 26, 2014, 08:00:41 AM
Quote from: DavidOfMA on November 25, 2014, 10:53:12 PM
So perhaps the request should instead be for a way to rescan a folder tree from within a script.
You can use the Rescan method available in the database class. Does this not work for you?
Title: Re: Call Renamer from a script
Post by: Ferdinand on November 26, 2014, 12:50:42 PM
Quote from: Mario on November 26, 2014, 08:00:41 AM
You can use the Rescan method available in the database class. Does this not work for you?

I haven't tried it, but reading the help file suggested to me that it rescanned files already in the DB, not new files that weren't.  I came to this conclusion because the input parameter is of type Files, i.e. already in the DB.  If you want to scan new files added recently to a folder, it didn't appear to me that it could do this.  I think a method to rescan a folder would be useful.
Title: Re: Call Renamer from a script
Post by: ubacher on November 26, 2014, 02:30:30 PM
Quote.....rescanned files already in the DB, not new files that weren't.

I tried the rescan some time back - I think it was also after suggestion by Mario - and found it did not do anything useful for me.