Skip to content

Commit

Permalink
docs: specify pre-translate default value (#624)
Browse files Browse the repository at this point in the history
  • Loading branch information
katerina20 authored and yzerk committed Aug 28, 2023
1 parent 358df86 commit 08e2870
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ private List<String> prepareLanguageIds(CrowdinProjectInfo projectInfo) {
List<String> projectLanguages = projectInfo.getProjectLanguages(false).stream()
.map(Language::getId)
.collect(Collectors.toList());
if (languageIds.size() == 1 && BaseCli.ALL.equals(languageIds.get(0))) {
if (languageIds.size() == 1 && BaseCli.ALL.equalsIgnoreCase(languageIds.get(0))) {
return projectLanguages;
} else {
String wrongLanguageIds = languageIds.stream()
Expand Down
2 changes: 1 addition & 1 deletion src/main/resources/messages/messages.properties
Original file line number Diff line number Diff line change
Expand Up @@ -321,7 +321,7 @@ crowdin.comment.resolve.id=Numeric ID of the string comment
# CROWDIN PRE-TRANSLATE
crowdin.pre-translate.usage.description=Pre-translate files via Machine Translation (MT) or Translation Memory (TM)
crowdin.pre-translate.usage.customSynopsis=@|fg(green) crowdin pre-translate|@ [CONFIG OPTIONS] [OPTIONS]
crowdin.pre-translate.language=Languages to which pre-translation should be applied
crowdin.pre-translate.language=Languages to which pre-translation should be applied. Default: ALL
crowdin.pre-translate.method=Defines pre-translation method. Supported values: mt, tm
crowdin.pre-translate.engine-id=Machine Translation engine Identifier
crowdin.pre-translate.auto-approve-option=Defines which translations added by TM pre-translation should be auto-approved. Supported values: all, except-auto-substituted, perfect-match-only. Default: none
Expand Down
1 change: 1 addition & 0 deletions website/mantemplates/crowdin-pre-translate.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ include::{includedir}/{command}.adoc[tag=picocli-generated-man-section-footer]
Crowdin CLI uses the `crowdin.yml` configuration to Pre-Translate files.

- At first, it finds local source files that match the source configuration pattern. Then CLI tries to find the corresponding files in the crowdin project. After that, CLI will request Pre-translation for the found file IDs (matching these files to local sources and configuration file).
- `-l`, `--language=language_code` - defines the language to which pre-translation should be applied. By default, pre-translation is applied for all project's target languages. link:https://developer.crowdin.com/language-codes/[Crowdin Language Codes].
- The `--engine-id` value you can find in the MT engine details (_Profile_ > _Machine translation_ for crowdin.com and _Dashboard_ > _Machine translation_ for Crowdin Enterprise)

=== Examples
Expand Down

0 comments on commit 08e2870

Please sign in to comment.