translations2db Command Line Utility
All translation operations are performed by using the translations2db
utility, either indirectly from a menu item in the SOS Stream GUI
or directly on the command line. This tool is installed in
/shared/sos/default/bin. There are a number of options, all of which begin
with --
. Different options may sometimes be run together at the same time,
e.g., translations2db --load_playlists --load_csv --verbose
.
Options
Permalink to Options--help
Permalink to --help
Lists all the valid options and their purpose.
--load_playlists
Permalink to --load_playlists
Use to load dataset translations.
Loads dataset name and description translations defined in playlist files
normally located in /shared/sos/locale to the data catalog. This option is an
alternative to --load_dataset_tsv
for loading dataset translations. It
accepts multi-line descriptions and uses the standard SOS playlist format.
If both --load_playlists
and --load_dataset_tsv
options are used together,
playlists will take precedence over tsv files for the same locales.
--load_dataset_tsv
Permalink to --load_dataset_tsv
Use to load dataset translations.
Loads dataset name and description translations defined in tab separated value
(tsv) files normally located in /shared/sos/locale to the data catalog. This
option is an alternative to --load_dataset_tsv
for loading dataset
translations. It does not allow multi-line descriptions, but tsv files are
easily loaded into spreadsheet programs, such as Excel or Google Sheets, for
convenient editing.
If both --load_playlists
and --load_dataset_tsv
options are used together,
playlists will take precedence over tsv files for the same locales.
--load_csv
Permalink to --load_csv
Use to load category and keyword translations.
Loads translations for major categories, subcategories, highlights categories, and keywords from comma separated value (csv) files normally located in /shared/sos/locale to the data catalog. Csv files are easily loaded into spreadsheet programs, such as Excel or Google Sheets, for convenient editing.
--load_highlights
Permalink to --load_highlights
Use to load highlights (spotlight) dataset translations.
Loads translations for highlights (spotlight) datasets from highlight dataset (hds) files normally located in /shared/sos/locale to the data catalog. Hds files are formatted similarly to playlists, but are specific to spotlight datasets, which can be temporary datasets not found elsewhere in the data catalog.
--load_all
Permalink to --load_all
Use to load all dataset-related translations.
Loads translations from playlist, csv, and hds files normally located in
/shared/sos/locale to the data catalog. This is equivalent to specifying all
of --load_playlists
, --load_csv
, and --load_highlights
.
--remove_all
Permalink to --remove_all
Use to clear all data-related translations loaded previously.
Removes all translations of dataset names & descriptions, highlights datasets, major & sub categories, highlights categories, and keywords, leaving only the default English text.
Does not affect user interface translations for the Remote App, Visual Playlist Editor, or any Kiosk-specific translations.
--tsv_to_ios_strings
Permalink to --tsv_to_ios_strings
Use to create translation files used by the Remote App user interface.
Converts translations for the Remote App’s user interface defined in tab separated value (tsv) files normally located in /shared/sos/locale/iOS to a special Apple strings format.
All iPad translations should be made to the tsv files, not in the generated strings files.
--vple_ts_to_tsv
Permalink to --vple_ts_to_tsv
Use to prepare translation files used by the Visual Playlist Editor user interface for editing in a spreadsheet.
Converts Visual Playlist Editor translation files in the ts format to tab separated value (tsv) files located in the linked directory /shared/sos/locale/playlist_editor. Tsv files are easily loaded into spreadsheet programs, such as Excel or Google Sheets, for convenient editing.
Do not use both --vple_ts_to_tsv
and --tsv_to_vple_ts
options together.
--tsv_to_vple_ts
Permalink to --tsv_to_vple_ts
Use to prepare translations edited in a spreadsheet for use by the Playlist Editor user interface.
Converts tab separated value (tsv) formatted files from a spreadsheet to the ts format used by the Playlist Editor user interface. Files must be located in the linked directory /shared/sos/locale/playlist_editor.
Do not use both --vple_ts_to_tsv
and --tsv_to_vple_ts
options together.
--generate_playlists
Permalink to --generate_playlists
Use to extract dataset translations from the data catalog into SOS playlists.
Generates playlists containing dataset names and descriptions for all the
locales in the data catalog. These files are written to a generated
subdirectory (normally /shared/sos/locale/generated). Any playlists
previously generated will be overwritten. Only one of --generate_playlist
and
--generate_dataset_tsv
options is typically used at a time.
The generated files may be copied to the root locale directory (normally
/shared/sos/locale) to update the dataset translations. They can also be used
as a starting point for translating a new language. The updated translations
are then loaded back into the data catalog with the --load_playlists
option.
--generate_dataset_tsv
Permalink to --generate_dataset_tsv
Use to extract dataset translations from the data catalog for editing in a spreadsheet.
Generates tab separated value (tsv) files containing dataset names and
descriptions for all the locales in the data catalog. These files are written
to a generated subdirectory (normally /shared/sos/locale/generated). Any tsv
files previously generated will be overwritten. Only one of
--generate_playlist
and --generate_dataset_tsv
options is typically used at
a time.
The generated files may be copied to the root locale directory (normally
/shared/sos/locale) and edited in a spreadsheet, such as Excel or Google
Sheets, to update the dataset translations. They can also be used as a starting
point for translating a new language. The updated translations are then saved
back to tsv files and loaded back into the data catalog with the
--load_dataset_tsv
option.
--generate_csv
Permalink to --generate_csv
Use to extract category & keyword translations from the data catalog for editing in a spreadsheet.
Generates comma separated value (csv) files containing major categories, subcategories, and keywords for all the locales in the data catalog. These files are written to a generated subdirectory (normally /shared/sos/locale/generated).
The generated files may be copied to the root locale directory (normally
/shared/sos/locale) and edited in a spreadsheet, such as Excel or Google
Sheets, to update the category and keyword translations. They can also be used
as a starting point for translating a new language. The updated translations
are then saved back to tsv files and loaded back into the data catalog with the
--load_csv option
.
--generate_highlights
Permalink to --generate_highlights
Use to extract highlights dataset translations from the data catalog into hds files.
Generates hds files containing highlights (spotlight) dataset names and descriptions for all the locales in the data catalog. These files are written to a generated subdirectory (normally /shared/sos/locale/generated). Any playlists previously generated will be overwritten.
The generated files may be copied to the root locale directory (normally
/shared/sos/locale) to update the highlights dataset translations. They can
also be used as a starting point for translating a new language. The updated
translations are then loaded back into the data catalog with the
--load_highlights
option.
--verbose
Permalink to --verbose
Used for troubleshooting.
Write timestamps with logged messages (must appear before --logging
).
--logging
Permalink to --logging
--logging [level]
Used for troubleshooting.
Set logging level for messages (default is INFO
). Valid level values are:
FATAL
, ERROR
, WARN
, INFO
, DEBUG
, TRACE
.
--root
Permalink to --root
--root [directory]
Used for troubleshooting.
Use a different translations root directory (default is /shared/sos/locale). The root directory is where all translation files (both original and generated) reside, except for Public Kiosk files which are in directories under /shared/sos/kiosk (see Public Kiosk Manual for more information).
--use_alternative_db
Permalink to --use_alternative_db
Used for troubleshooting.
Use an alternate database in the --root
directory copied from
/shared/sos/database. Do not use for the iPad!
--generate_sosx_tsv
Permalink to --generate_sosx_tsv
For NOAA Internal Use.
Generates tab separated value (tsv) files containing dataset names and descriptions for all the locales to work with SOS Explorer®. These files are written to a generated subdirectory (normally /shared/sos/locale/generated). An SOSX tsv file previously generated will be overwritten.