<commit_before># gulp-chown [![Build Status](https://travis-ci.org/sindresorhus/gulp-chown.svg?branch=master)](https://travis-ci.org/sindresorhus/gulp-chown)

> Change permissions of [Vinyl](https://github.com/wearefractal/vinyl) files


## Install

```
$ npm install --save-dev gulp-chown
```


## Usage

```js
var gulp = require('gulp');
var chown = require('gulp-chown');

gulp.task('default', function () {
	return gulp.src('src/app.js')
		.pipe(chown('sindresorhus'))
		.pipe(gulp.dest('dist'));
});
```

or

```js
var gulp = require('gulp');
var chown = require('gulp-chown');

gulp.task('default', function () {
	return gulp.src('src/app.js')
		.pipe(chown(501))
		.pipe(gulp.dest('dist'));
});
```


## API

### chown(userId, groupId)

Arguments must be of the same type.

#### userId

*Required*  
Type: `string`, `number`

The user name or [user id](https://en.wikipedia.org/wiki/User_identifier) to change ownership to.

#### groupId

Type: `string`, `number`

The group name or [group id](https://en.wikipedia.org/wiki/Group_identifier) to change ownership to.


## Tip

Combine it with [gulp-filter](https://github.com/sindresorhus/gulp-filter) to only change ownership of a subset of the files.

```js
var gulp = require('gulp');
var gFilter = require('gulp-filter');
var chown = require('gulp-chown');

var filter = gFilter('src/vendor-*.js');

gulp.task('default', function () {
	return gulp.src('src/*.js')
		// filter a subset of the files
		.pipe(filter)
		// change ownership of them
		.pipe(chown('sindresorhus'))
		// bring back the previously filtered out files
		.pipe(filter.restore())
		.pipe(gulp.dest('dist'));
});
```


## License

MIT © [<NAME>](http://sindresorhus.com)<commit_msg>readme tweaks<commit_after># gulp-chown [![Build Status](https://travis-ci.org/sindresorhus/gulp-chown.svg?branch=master)](https://travis-ci.org/sindresorhus/gulp-chown)

> [Change owner](https://en.wikipedia.org/wiki/Chown) of [Vinyl](https://github.com/gulpjs/vinyl) files


## Install

```
$ npm install --save-dev gulp-chown
```


## Usage

```js
const gulp = require('gulp');
const chown = require('gulp-chown');

gulp.task('default', () => {
	return gulp.src('src/app.js')
		.pipe(chown('sindresorhus'))
		.pipe(gulp.dest('dist'));
});
```

or

```js
const gulp = require('gulp');
const chown = require('gulp-chown');

gulp.task('default', () => {
	return gulp.src('src/app.js')
		.pipe(chown(501))
		.pipe(gulp.dest('dist'));
});
```


## API

### chown(userId, groupId)

Arguments must be of the same type.

#### userId

*Required*  
Type: `string`, `number`

The user name or [user id](https://en.wikipedia.org/wiki/User_identifier) to change ownership to.

#### groupId

Type: `string`, `number`

The group name or [group id](https://en.wikipedia.org/wiki/Group_identifier) to change ownership to.


## Tip

Combine it with [gulp-filter](https://github.com/sindresorhus/gulp-filter) to only change ownership of a subset of the files.

```js
const gulp = require('gulp');
const gFilter = require('gulp-filter');
const chown = require('gulp-chown');

const filter = gFilter('src/vendor-*.js');

gulp.task('default', () => {
	return gulp.src('src/*.js')
		// filter a subset of the files
		.pipe(filter)
		// change ownership of them
		.pipe(chown('sindresorhus'))
		// bring back the previously filtered out files
		.pipe(filter.restore())
		.pipe(gulp.dest('dist'));
});
```


## Related

- [gulp-chmod](https://github.com/sindresorhus/gulp-chmod) - Change permissions of Vinyl files


## License

MIT © [<NAME>](http://sindresorhus.com)
{'fraction_non_alphanumeric': 0.1958965711073637, 'fraction_numerical': 0.0016863406408094434, 'mean_word_length': 4.359939759036145, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 10, 'https://': 14, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5464891', 'n_tokens_mistral': 1355, 'n_tokens_neox': 1296, 'n_words': 280}