# gulp-mono-angular-gettext

> Gulp plugin for extracting/compiling angular-gettext strings in monorepo

Latest version **3.0.0** (published 2022-11-16) · MIT license · 0 weekly downloads

## Install

```sh
npm install gulp-mono-angular-gettext
pnpm add gulp-mono-angular-gettext
yarn add gulp-mono-angular-gettext
bun add gulp-mono-angular-gettext
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 3.0.0 |
| Published | 2022-11-16 |
| First published | 2022-11-16 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Node | >=18.0.0 |
| Dependencies | 4 |
| Unpacked size | 6.9 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 33 |
| Author | Gabe Gorelick |
| Maintainers | jonhammer |
| Keywords | gulpplugin, angular, gettext, extract |

## Links

- npm: https://www.npmjs.com/package/gulp-mono-angular-gettext
- Repository: https://github.com/gabegorelick/gulp-angular-gettext
- Homepage: https://github.com/gabegorelick/gulp-angular-gettext#readme
- Issues: https://github.com/gabegorelick/gulp-angular-gettext/issues
- npm.io page: https://npm.io/package/gulp-mono-angular-gettext

## Dependencies (4)

- [vinyl](https://npm.io/package/vinyl.md) ^2.2.0
- [through2](https://npm.io/package/through2.md) ^2.0.1
- [plugin-error](https://npm.io/package/plugin-error.md) ^1.0.1
- [angular-gettext-tools](https://npm.io/package/angular-gettext-tools.md) ^2.2.0

## Recent versions

- 3.0.0 (latest) — 2022-11-16

## README

# [gulp](http://gulpjs.com)-mono-angular-gettext

This is a fork of [gulp-angular-gettext](https://www.npmjs.com/package/gulp-angular-gettext) 2.3.0

It merely changes how source references are reported as this fork will report workspace
relative paths in references.

This approach is better for use in monorepos with global repo translation jobs.

The reason this change is in a fork is that it is a breaking change.

> Extract and compile translatable strings using [angular-gettext](http://angular-gettext.rocketeer.be)
This is a fork of 
## Install

Install with [npm](https://npmjs.org/package/gulp-mono-angular-gettext)

```sh
npm install --save-dev gulp-mono-angular-gettext
```

## Example

```js
var gulp = require('gulp');
var gettext = require('gulp-angular-gettext');

gulp.task('pot', function () {
    return gulp.src(['src/partials/**/*.html', 'src/scripts/**/*.js'])
        .pipe(gettext.extract('template.pot', {
            // options to pass to angular-gettext-tools...
        }))
        .pipe(gulp.dest('po/'));
});

gulp.task('translations', function () {
	return gulp.src('po/**/*.po')
		.pipe(gettext.compile({
		    // options to pass to angular-gettext-tools...
		    format: 'json'
        }))
		.pipe(gulp.dest('dist/translations/'));
});
```

## API

### `.extract([out], [options])`
* `out` - an optional String representing the name of the POT file to output. If this option is given, a single POT file
  will be generated for the entire set of input files. If this option is omitted, one POT file will be generated
  __per__ input file.
* `options` - an optional object to pass to [angular-gettext-tools](https://github.com/rubenv/angular-gettext-tools)
  `Extractor`

### `.compile([options])`
* `options` - an optional object to pass to [angular-gettext-tools](https://github.com/rubenv/angular-gettext-tools)
  `Compiler`

---
_Source: https://npm.io/package/gulp-mono-angular-gettext · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
