Suggestion - Save Templates into the rename pattern
#1
Hi, 

I use a different rename pattern for 1080p Remux & MicroHD.

Because of that, I have the pattern saved into a note and I just copy & paste in TMM when renaming one or other content.

It would be great to have the possibility to save those templates (folder name & filename pattern) into TMM itself, so you can choose what pattern you want to use when renaming.
#2
Hi, 

Any possibility this could be implemented?  should be quite easy to do and it will save some time to many of us.

Thanks in advanced.
#3
(2020-12-04, 09:33)jhoyos Wrote: for 1080p Remux & MicroHD.

Are they field values or part of video filename?
Probably you could achieve that using nested if syntax.
If it's part of filename, you could still do it using a replace renderer.

Say, remux.csv removes remux, this will output a different naming depending on whether the filename contains remux:
Code:
${if movie.mainVideoFile.basename = movie.mainVideoFile.basename;replace(remux.csv)}no remux${else}remux${end}
#4
The rename pattern depend basically from the source.  I have several sources in TMM, ones that contains Remux and others that contains no Remux.  I use a different patter when renaming ones or anothers... so that's why I would like to be able to choose between saved patterns.

Regards,
#5
(2021-01-18, 18:38)jhoyos Wrote: I have several sources in TMM, ones that contains Remux and others that contains no Remux.

Then you could check whether source contains remux or not, and apply different naming:
Code:
${if movie.mediaSource = movie.mediaSource;replace(remux.csv)}no remux${else}remux${end}
#6
(2021-01-19, 07:30)tars Wrote:
(2021-01-18, 18:38)jhoyos Wrote: I have several sources in TMM, ones that contains Remux and others that contains no Remux.

Then you could check whether source contains remux or not, and apply different naming:
Code:
${if movie.mediaSource = movie.mediaSource;replace(remux.csv)}no remux${else}remux${end}

Thanks for your help, but I have no idea how to implement that.  Considering I use these codes for renaming:

No Remux
${title} (${year}) [${if  movie.mediaInfoVideoFormat='2160p'}4K${else}${movie.mediaInfoVideoFormat}${end} ${if movie.mediaInfoVideoCodec='h264'}x264${else}${if movie.mediaInfoVideoCodec='h265'}x265${else}${movie.mediaInfoVideoCodec}${end}${end} ${movie.mediaInfoAudioCodec}]${if movie.mediaInfoAudioCodecList.length = '1' } ${else} [Dual${if movie.mainVideoFile.subtitles} + Subs${end}] ${end}[ID ${movie.tmdbId}]

Remux
${title} (${year}) [${if  movie.mediaInfoVideoFormat='2160p'}4K${else}${movie.mediaInfoVideoFormat}${end} Remux ${if movie.mediaInfoVideoCodec='h264'}x264${else}${if movie.mediaInfoVideoCodec='h265'}x265${else}${movie.mediaInfoVideoCodec}${end}${end} ${movie.mediaInfoAudioCodec}] [ID ${movie.tmdbId}]

How would I have to write that condition, to consider one or another depending on the source?  my sources that are Remux, have "Remux" into the directory name, so it could work, but I don't know how to implement that condition.

Thanks in advanced.
#7
(2021-01-26, 12:13)jhoyos Wrote: my sources that are Remux, have "Remux" into the directory name

Then try "path" in place of "mediaSource" for the code I gave you.
You could replace "remux" & "no remux" in my code with each of your whole renaming template.
#8
Thanks for your help.  However, there are other questions... I don't have just 2 sources, one Remux and other no Remux.  I have several sources for Remux and no Remux:
1080p Remux
1080p Remux Animation
4K Remux
4K Remux Animation

That way... is there any condition to says... if movie.path CONTAINS "Remux", XXX, if not, YYY

Anyway, I think it still will be easier to have the possibility to save the rename patern and be able to choose at your convenience.  I think it will be a feature many will love, for example when rename Remux, no Remux, Webdl, or whatever.  Many people use different patterns depending on the source.

Thanks a lot.
#9
You already said that.
You don't have to try it, if you don't want.
Now I think I shouldn't have answered when you actually didn't ask for any help.
#10
(2021-01-27, 11:50)tars Wrote: You already said that.
You don't have to try it, if you don't want.
Now I think I shouldn't have answered when you actually didn't ask for any help.

I am sorry if I have offended to you, since it was not my intention.  I really appreciate your help, and will be happy to implement your solution.  I definitely prefer the other solution (my suggestion), but your could work as good as my suggestion and will solve my problem in any case, which it is my intention.

So... if I have wrotten something that made you think I didn't appreciate your help, I really apologize.  I am not a native english speaker and I might have written something that could be missundertood.

So again, my apologies.

I would understand you don't want to help me anymore, but I really would appreciate your help if there is any possibility to include in that expression the conditional considering the path contains Remux, and not specifing just one path.

Thanks a lot.
#11
The code is already checking whether the path contains remux or not, if you, as I said, use "path" in place of "mediaSource".

If somebody else had told me something like this, I would have already tried several times with some test files to see if that works.
But you never try it (testing only requires previewing in tmm's renamer settings dialog) and just keep asking. So I wasn't sure you really need any help and I was wasting your time.
#12
(2021-01-27, 14:25)tars Wrote: The code is already checking whether the path contains remux or not, if you, as I said, use "path" in place of "mediaSource".

If somebody else had told me something like this, I would have already tried several times with some test files to see if that works.
But you never try it (testing only requires previewing in tmm's renamer settings dialog) and just keep asking. So I wasn't sure you really need any help and I was wasting your time.

Of course I tried your code, and it always write "no remux.mkv", no matters it has Remux on the path or not.  

This is the code I tried, just to test:

${if movie.path = movie.path;replace(remux.csv)}no remux${else}remux${end}

And it always rename the same -->  no remux.mkv

This is the file, same in two different directories:  007 - Al servicio secreto de su Majestad (1969) [1080p Remux x264 DTS] [ID 668]

When applying that code, I receive this result in "testing" mode, as you said.  I already did that with no success.
V:\SDD - PELICULAS\SDD - PELICULAS\01 - Best of hasta 1080p\1960 - 1969\no remux.mkv
V:\SDD - PELICULAS\SDD - PELICULAS\03 - 1080p Remux\1900 - 1979\no remux.mvk

And to be honest, I would know how to change your code, since to me it doesn't make any sense.

I also tried this:
${if movie.path = remux}no remux${else}remux${end}
${if movie.path = remux.csv}no remux${else}remux${end}

And then, it always result in "remux.mkv".

I am sorry, and I know you are pissed of, but I don't know how to code and I haven't figure out by myself how to change your line so it can work.

Thanks a lot.
#13
Did you create and put remux.csv in data folder? Then what's the content of the file?
#14
Just in case you didn't get what I meant by "Say, remux.csv removes remux", see this: https://www.tinymediamanager.org/blog/jm...-renderer/
#15
(2021-01-28, 12:59)tars Wrote: Did you create and put remux.csv in data folder? Then what's the content of the file?

No, I haven't done anything.  I just copied your code.

Should I create a remux.csv file inside data folder containing all the paths that contains Remux? or what do I have to do?

Logout Mark Read Team Forum Stats Members Help
Suggestion - Save Templates into the rename pattern0