<commit_before>[![CircleCI](https://circleci.com/gh/cyrale/gulpfile.js.svg?style=svg)](https://circleci.com/gh/cyrale/gulpfile.js)
[![npm version](https://badge.fury.io/js/gulpfile.js.svg)](https://badge.fury.io/js/gulpfile.js)
[![Dependency Status](https://david-dm.org/cyrale/gulpfile.js.svg?theme=shields.io)](https://david-dm.org/cyrale/gulpfile.js)
[![devDependency Status](https://david-dm.org/cyrale/gulpfile.js/dev-status.svg?theme=shields.io)](https://david-dm.org/cyrale/gulpfile.js#info=devDependencies)

Because I spent too much time redoing my gulp tasks, I make this to work
with a unique configuration file written in YAML.

The project is inspired by [**Blendid** _(formerly known as Gulp Starter)_](https://github.com/vigetlabs/blendid).

## New in 3.0.0

- The directory where `gulpconfig.yml` is the current working directory where
you could put configuration files like `.babelrc`, `.browserslistrc`, 
`.eslintrc`...
- Discreetly introduce in previous version, `svgstore` is officially in this 
version. You could combine SVG files in One.
- Browserify is now manage by it's own tasks.
- New `webpack` tasks to package javascript files.
- New `clean` task to delete directories and files before other tasks run.
- **Experimental** `revision` that build a JSON file with all generated files 
and some hashes (MD5, SHA1 and SHA256) sort by tasks. This could be used in URL
parameters as cache buster.
- Build tasks now exit on error with an error code equal to 1, that mean you
can use it in CI/CD process.

## Breaking changes in 3.0.0

- `javascript` tasks **no longer use** `browserify`. It's only a concatenation 
task with Babel.
- In `sass` tasks, default sort for media queries is "mobile" instead of desktop.
- Remove `name` settings on `fonts` tasks.
- Data for `pug` tasks is no longer merged between global and task settings.

## Execution graph

Here's how all the tasks run:

<img src="https://github.com/cyrale/gulpfile.js/raw/3.0.x/assets/graph.svg?sanitize=true" alt="Execution graph" width="500px" />

With this organisation, you can chain some process. For example, you can bundle
your scripts with Browserify or Webpack and pass it to default Javascript task.
Another example concern images, you can build sprites and optimize it by passing
it to images task.

## Quick start on a fresh project (empty directory)

Install **gulpfile.js**:

```bash
npm init
npm install gulpfile.js --save-dev --save-exact
npx gulpfile
```

Create configuration files:

```bash
touch gulpconfig.yml
touch .eslintrc
```

Start **gulpfile.js**:

```bash
npx gulpfile
```

## Commands

```bash
npx gulpfile
```

This is where the magic happens. The perfect front-end workflow. This runs the
development task, which starts compiling, watching, and live updating all our
files as we change them. Browsersync will start a server on port 3000, or do
whatever you've configured it to do. You'll be able to see live changes in all
connected browsers.

```bash
npx gulpfile build
```

Compiles files to your destination directory.

It's a good idea to add aliases for these commands to your package.json scripts object.

package.json:

```json
{
  "scripts": {
    "start": "npx gulpfile",
    "build": "npx gulpfile build"
  }
}
```<commit_msg>Change script name<commit_after>[![CircleCI](https://circleci.com/gh/cyrale/gulpfile.js.svg?style=svg)](https://circleci.com/gh/cyrale/gulpfile.js)
[![npm version](https://badge.fury.io/js/gulpfile.js.svg)](https://badge.fury.io/js/gulpfile.js)
[![Dependency Status](https://david-dm.org/cyrale/gulpfile.js.svg?theme=shields.io)](https://david-dm.org/cyrale/gulpfile.js)
[![devDependency Status](https://david-dm.org/cyrale/gulpfile.js/dev-status.svg?theme=shields.io)](https://david-dm.org/cyrale/gulpfile.js#info=devDependencies)

Because I spent too much time redoing my gulp tasks, I make this to work
with a unique configuration file written in YAML.

The project is inspired by [**Blendid** _(formerly known as Gulp Starter)_](https://github.com/vigetlabs/blendid).

## New in 3.0.0

- The directory where `gulpconfig.yml` is the current working directory where
you could put configuration files like `.babelrc`, `.browserslistrc`, 
`.eslintrc`...
- Discreetly introduce in previous version, `svgstore` is officially in this 
version. You could combine SVG files in One.
- Browserify is now manage by it's own tasks.
- New `webpack` tasks to package javascript files.
- New `clean` task to delete directories and files before other tasks run.
- **Experimental** `revision` that build a JSON file with all generated files 
and some hashes (MD5, SHA1 and SHA256) sort by tasks. This could be used in URL
parameters as cache buster.
- Build tasks now exit on error with an error code equal to 1, that mean you
can use it in CI/CD process.

## Breaking changes in 3.0.0

- `javascript` tasks **no longer use** `browserify`. It's only a concatenation 
task with Babel.
- In `sass` tasks, default sort for media queries is "mobile" instead of desktop.
- Remove `name` settings on `fonts` tasks.
- Data for `pug` tasks is no longer merged between global and task settings.

## Execution graph

Here's how all the tasks run:

<img src="https://github.com/cyrale/gulpfile.js/raw/3.0.x/assets/graph.svg?sanitize=true" alt="Execution graph" width="500px" />

With this organisation, you can chain some process. For example, you can bundle
your scripts with Browserify or Webpack and pass it to default Javascript task.
Another example concern images, you can build sprites and optimize it by passing
it to images task.

## Quick start on a fresh project (empty directory)

Install **gulpfile.js**:

```bash
npm init
npm install gulpfile.js --save-dev --save-exact
npx gulpfile.js
```

Create configuration files:

```bash
touch gulpconfig.yml
touch .eslintrc
```

Start **gulpfile.js**:

```bash
npx gulpfile.js
```

## Commands

```bash
npx gulpfile.js
```

This is where the magic happens. The perfect front-end workflow. This runs the
development task, which starts compiling, watching, and live updating all our
files as we change them. Browsersync will start a server on port 3000, or do
whatever you've configured it to do. You'll be able to see live changes in all
connected browsers.

```bash
npx gulpfile.js build
```

Compiles files to your destination directory.

It's a good idea to add aliases for these commands to your package.json scripts object.

package.json:

```json
{
  "scripts": {
    "start": "npx gulpfile.js",
    "build": "npx gulpfile.js build"
  }
}
```
{'fraction_non_alphanumeric': 0.11238707701730209, 'fraction_numerical': 0.006430868167202572, 'mean_word_length': 4.349713349713349, 'pattern_counts': {'":': 6, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 20, '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': '843551', 'n_tokens_mistral': 2165, 'n_tokens_neox': 2032, 'n_words': 790}