flownative / neos-trados

Neos的XML导入/导出,适用于Trados翻译

安装数:4,348

依赖项: 0

建议者: 0

安全: 0

星标: 5

关注者: 6

分支: 9

开放问题: 4

类型:neos-package

2.2.0 2022-09-13 13:53 UTC

This package is auto-updated.

Last update: 2024-09-13 18:36:37 UTC


README

MIT license Packagist Maintenance level: Acquaintance

Neos的Trados支持

功能

  • 将内容导出为Trados可以处理的XML格式,并只包含所需数据
  • 将翻译导入特定语言

安装

composer require flownative/neos-trados

用法

导出命令

Export sites content (e.g. trados:export --filename "acme.com.xml" --source-language "en")

COMMAND:
  flownative.neos.trados:trados:export

USAGE:
  ./flow trados:export [<options>] <starting point> <source language>

ARGUMENTS:
  --starting-point              The node with which to start the export, relative to the
                                site node. Optional.
  --source-language             The language to use as base for the export.

OPTIONS:
  --target-language             The target language for the translation, optional.
  --filename                    Path and filename to the XML file to create.
  --modified-after
  --exclude-child-documents     If child documents should not be included in the export.

导入命令

Import sites content (e.g. trados:import --filename "acme.com.xml" --workspace "czech-review")

COMMAND:
  flownative.neos.trados:trados:import

USAGE:
  ./flow trados:import [<options>] <filename>

ARGUMENTS:
  --filename           Path and filename to the XML file to import.

OPTIONS:
  --target-language    The target language for the translation, optional if
                       included in XML.
  --workspace          A workspace to import into, optional but recommended

工作流程

工作流程通常如下

  1. 使用trados:export导出网站内容
  2. XML由某些翻译机构进行翻译
  3. 使用trados:import将翻译后的XML导入到新的工作区
  4. 在工作区模块中审查和发布更改

配置

命令通常导出类型为的所有属性。如果您想排除某些属性,可以在您的NodeTypes.yaml文件中配置,如下所示

'TYPO3.Neos:Document':
  options:
    Flownative:
      Neos:
        Trados:
          properties:
            twitterCardType:
              skip: true

为了配置哪个维度应该被翻译,可以使用Settings.yaml进行配置

Flownative:
  Neos:
    Trados:
      languageDimension: 'language_country'

Trados配置

为了以仅显示应翻译的内容的方式配置Trados,您需要创建一个自定义XML文件类型作为过滤器。它需要指定应过滤的标签。这解释了:[链接](https://www.youtube.com/watch?v=TrxLLP5OaIc)

感谢Robin Clemens的提示!