A command line interface for angular-gettext-tools
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
bin
example
.gitignore
.travis.yml
README.md
acceptance-test.sh
package.json

README.md

angular-gettext-cli Build Status

A command line interface for angular-gettext-tools

Installation

npm install angular-gettext-cli -g for global using or npm install angular-gettext-cli --save-dev for local.

Extraction:

angular-gettext-cli --files './app/*.+(js|html)' --exclude '**/*.spec.js' --dest './extract.pot' --marker-name i18n

Parameters:

  • --files - a glob pattern to specify files to process
  • --exclude - (optional) a glob pattern to specify files to ignore
  • --dest - path to file to write extracted words.
  • --marker-name - (optional) a name of marker to search in js-files (see angular-gettext-tools)
  • --marker-names - (optional) comma separated string of marker names to search for in the js-files (see angular-gettext-tools)
  • --attributes - (optional) comma separated string of marker names to search for in the html-files (see angular-gettext-tools)

Compilation:

angular-gettext-cli --compile --files 'test/*.po' --dest 'test/output.js' --format javascript --module gettext-test

Parameters:

  • --files - a glob pattern to specify files to process
  • --dest - path to file to write extracted words.
  • --format - javascript or json. Default is javascript
  • --module - For the javascript output format, the angular module name to use in the output file. Default is gettext

For more options, see angular-gettext-tools.