Closed dmlh closed 5 years ago
It does only translates into German for me, too. The Readme says:
To activate this workflow use the default keyword
dl
, enter the passage you wanna get translated and end the input with.
. Source and destination language will be inferred automatically.
I'm trying to figure out if there's a way to pass a parameter to the workflow to get translations into other languages, too?
Two options that could be implemented:
setting the preferred destination language in the workflow.
passing the target language, for example "dl today will be nice weather > fr" or for more than one target language "dl will it rain today? > fr de".
What do you think?
It would be useful to be able to change languages using variables, and it's pretty simple to implement
@AlexanderWillner I like both ideas, this would also be consistent with m9dfukc's workflow. Personally I prefer to set the preferred destination language in the workflow. This allows me to create the workflows dlde
, defr
for my most commons translations. Passing the target language is also great though since it doesn't require to copy and modify the workflow for fast translations.
Implemented it via environment variable. Please test.
I'm not so sure about the advantage of using the environment variable. In m9dfukc's workflow I could just copy the Script Filter, set the keyword to dlfr
and modify the script to use $default_language = 'FR';
. With the environment variable, I set the language for the whole workflow again, so I don't see the advantage here? I always have to open the workflow and change the variable there if I want to get translations for another language? Or do I miss something obvious?
However, I solved it now like this:
I'm sure the environment variable will be of some use since user @dotiful requested it that way. Thank you for taking the time.
Good idea. Will provide this option as well.
Thank you, this works perfectly :) It kept giving me translations into German only - but I fixed this by deleting the other languages and just leaving the ones I want (EN & ES). I rely on this workflow a lot, so happy you found a fix!