Transliterating filenames through the new file renaming tool?
Hi,
I am just working on to moving my automatic file renaming from something based on citation keys (Better BibTeX) to the "native" Zotero renamer, and it works really well. But I am missing the option to transliterate names and titles of foreign books (cyrillic, turkish, arabic) into the Latin alphabet, which is available and worked nicely in Better BibTex.
Does this option even exist in Zotero? What does the "language" field even do (see link below)?
I used only this as a guide so far: https://www.zotero.org/support/file_renaming
This is the "code" I came up with, very crude, but it works nicely for my needs:
{{ if {{ editorsCount > 1 }} }}
{{ authors max=1 name="family-given" case='upper' initialize='given' }}
{{ authors name="family-given" initialize='given' suffix=", " replaceFrom='[^,]+' replaceTo=''}}
{{ editors name="given-family" initialize='given' suffix=" (eds.) "}}
{{ title replaceFrom='(: | ,)', replaceTo='_', regexOpts="gi"}}
{{ else }}
{{ authors max=1 name="family-given" case='upper' initialize='given' }}
{{ authors name="family-given" initialize='given' suffix=", " replaceFrom='[^,]+' replaceTo=''}}
{{ editors name="given-family" initialize='given' suffix=" (ed.) "}}
{{ title replaceFrom='(: | ,)', replaceTo='. ', regexOpts="gi" }}
{{ endif }} {{year }}
Which gives me file names in the format:
MUPPET A., B. Muppet2, C. Muppet3 (eds.), Titlepart1. Titlepart2 year.pdf
Just to clarify once more, I would like to be able to automatically transliterate everything to the latin alphabet, if at all possible, for ease of searching in my folder.
Thank you in advance and all the best!
I am just working on to moving my automatic file renaming from something based on citation keys (Better BibTeX) to the "native" Zotero renamer, and it works really well. But I am missing the option to transliterate names and titles of foreign books (cyrillic, turkish, arabic) into the Latin alphabet, which is available and worked nicely in Better BibTex.
Does this option even exist in Zotero? What does the "language" field even do (see link below)?
I used only this as a guide so far: https://www.zotero.org/support/file_renaming
This is the "code" I came up with, very crude, but it works nicely for my needs:
{{ if {{ editorsCount > 1 }} }}
{{ authors max=1 name="family-given" case='upper' initialize='given' }}
{{ authors name="family-given" initialize='given' suffix=", " replaceFrom='[^,]+' replaceTo=''}}
{{ editors name="given-family" initialize='given' suffix=" (eds.) "}}
{{ title replaceFrom='(: | ,)', replaceTo='_', regexOpts="gi"}}
{{ else }}
{{ authors max=1 name="family-given" case='upper' initialize='given' }}
{{ authors name="family-given" initialize='given' suffix=", " replaceFrom='[^,]+' replaceTo=''}}
{{ editors name="given-family" initialize='given' suffix=" (ed.) "}}
{{ title replaceFrom='(: | ,)', replaceTo='. ', regexOpts="gi" }}
{{ endif }} {{year }}
Which gives me file names in the format:
MUPPET A., B. Muppet2, C. Muppet3 (eds.), Titlepart1. Titlepart2 year.pdf
Just to clarify once more, I would like to be able to automatically transliterate everything to the latin alphabet, if at all possible, for ease of searching in my folder.
Thank you in advance and all the best!
-
iagogvRelated: https://forums.zotero.org/discussion/116484/feature-request-remove-accents-diacritics-from-filenames#latest (I assume the solution should include both)
-
FRlefthandofdarknessThank you, I learnt a lot, but it includes no solution about transliteration - the only thing being discussed is the removal of diacritics.
Upgrade Storage