crowdin string add
Description​
Add a new source string
Synopsis​
crowdin string add <text> [CONFIG OPTIONS] [OPTIONS]
Arguments​
<text>
Set text for the new source string
Options​
--identifier
=…
Set an identifier for the new source string
--max-length
=…
Set a max. length of the translated text for the new source string
--context
=…
Add a context for the new source string
--file
=…
Specify a file path to add the new source string to. Multiple files can
be specified
--label
=…
Attach labels to strings (multiple labels can be specified)
-b
, --branch
=…
Specify branch name. Default: none
--hidden
Specifies whether the added strings should be hidden or not
--one
=…
Plural form one (singular)
--two
=…
Plural form two (dual)
--few
=…
Plural form few (paucal)
--many
=…
Plural form many
--zero
=…
Plural form zero
-V
, --version
Display version information and exit
-h
, --help
Display help message and exit
--no-progress
Disable progress on executed command
-v
, --verbose
Provide more information about the command execution
--no-colors
Disable colors and styles
-c
, --config
=…
Specify a path to the configuration file. Default: crowdin.yml
or
crowdin.yaml
--identity
=…
Specify a path to user-specific credentials
--plain
Provide plain, processable output
Config Options​
-T
, --token
=…
Personal access token required for authentication
--base-url
=…
Base URL of Crowdin server for API requests execution
--base-path
=…
Path to your project directory on a local machine
-i
, --project-id
=…
Numeric ID of the project
Examples​
Add a new string with the app.home
key to the src/values/strings.xml
file:
crowdin string add Home --file src/values/strings.xml --identifier "app.home"
Add a new string with the app.download
key to the
src/values/strings.xml
file (branch main
):
crowdin string add Download --file src/values/strings.xml --identifier "app.download" --branch main
Add a new string with the app.hello
key to the strings.xml
file,
with labels app
and home
:
crowdin string add "Hello world" --file strings.xml --identifier "app.hello" --label app --label home
Add a new plural string:
crowdin string add Cats --file strings.xml --identifier "ui.cats" --one "cat"
In this example, the <text>
argument is used as the "other" plural
form.
If your source language contains more plural forms, you can also specify them using the `--two', `--few', `--many' and `--zero' options.