0.0.6 • Published 9 days ago

i18n-openai-translate v0.0.6

Weekly downloads
-
License
ISC
Repository
github
Last release
9 days ago

i18n-openai-translate 🌍🔀📚

🤖 Automagically translate your i18n JSON files into multiple languages using OpenAI's API! 🌐

⚠️ NOT FOR PRODUCTION


🚀 Features

  • 🌍 Translate en.json into multiple languages (fr.json, es.json, etc.)
  • 💾 Saves directly into your i18n folder.
  • ⚙️ Easy to configure.
  • 🚫 No more manual translations!

🛠 Installation

Use npm to install i18n-openai-translate.

npm install -g i18n-openai-translate

⚙️ Usage

Simply run the following command inside your i18n folder:

i18n-openai-translate  -i en.json --to fr

📝 Configuration

You can set up your OpenAI API Key by setting the OPENAI_API_KEY environment variable.

Here are the usage flags for the program:

--help: Shows the help message for the program.
--version: Shows the version number of the program.
-f, --from: Specifies the language to translate from.
-t, --to: Specifies the language to translate to.
-l, --languages: Specifies the languages to translate to as an array.
-c, --ctx: Specifies additional context to use.
-s, --save: Specifies whether to save the output to a file or stdout.
-p, --pretty: Specifies whether to pretty print the output.
-i, --input: Specifies the input file to translate, which is required.

🔒 License

This project is GPLv2 licensed.

0.0.5

9 days ago

0.0.6

9 days ago

0.0.4

6 months ago

0.0.3

6 months ago

0.0.2

7 months ago

0.0.1

7 months ago