0
Fork 0
mirror of https://github.com/logto-io/logto.git synced 2024-12-16 20:26:19 -05:00

chore(cli): update translate command description (#3662)

This commit is contained in:
Gao Sun 2023-04-03 14:59:46 +08:00 committed by GitHub
parent d082d24561
commit 1d4662ebc1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 2 deletions

View file

@ -10,7 +10,8 @@ import { createFullTranslation } from './utils.js';
const create: CommandModule<{ path?: string }, { path?: string; 'language-tag': string }> = {
command: ['create <language-tag>', 'c'],
describe: 'Create a new language translation',
describe:
'Create a new language translation using ChatGPT. Note the environment variable `OPENAI_API_KEY` is required to work.',
builder: (yargs) =>
yargs.positional('language-tag', {
describe: 'The language tag to create, e.g. `af-ZA`.',

View file

@ -10,7 +10,8 @@ import { type CreateFullTranslation, baseLanguage, createFullTranslation } from
const sync: CommandModule<{ path?: string }, { path?: string }> = {
command: ['sync'],
describe: 'Translate all untranslated phrases.',
describe:
'Translate all untranslated phrases using ChatGPT. Note the environment variable `OPENAI_API_KEY` is required to work.',
handler: async ({ path: inputPath }) => {
const queue = new PQueue({ concurrency: 5 });
const instancePath = await inquireInstancePath(inputPath);