Skip to content

linkorb/xliff-tools

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Xliff Tool

Depfu

Xliff Tool is a tool for generating and updating xliff from json and also json from xliff.

Installation

$ npm i -D xliff_tool

Requirements

  • npm
  • node.js

Usage

const xliffTool = require('xliff_tool');

const src = './strings.en.json';
const tar = './strings.de.xliff';

xliffTool.j2x(src, tar, 'En', 'De'); // export 
const xliffTool = require('xliff_tool');

const src = './strings.de.xliff';
const tar = './strings.en.json';

xliffTool.x2j(src, tar);

Development

$ npm i -D xliff_tool

$ node bash.js j2x ./strings.en.json ./strings.de.xliff En De // generate xliff from json
$ node bash.js x2j ./strings.de.xliff ./strings.de.json // generate json from xliff

$ node prompt.js j2x // generate xliff from json
$ node prompt.js x2j // generate json from xliff

$ sudo node link
$ j2x ./strings.en.json ./strings.de.xliff En De // generate xliff from json
$ x2j ./strings.de.xliff ./strings.de.json // generate json from xliff

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

License

MIT

About

XLIFF command-line tools

Resources

Code of conduct

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published