<commit_before>[![npm](https://img.shields.io/npm/v/start-codecov.svg?style=flat-square)](https://www.npmjs.com/package/start-codecov)
[![travis](http://img.shields.io/travis/start-runner/codecov.svg?style=flat-square)](https://travis-ci.org/start-runner/codecov)
[![deps](https://img.shields.io/gemnasium/start-runner/codecov.svg?style=flat-square)](https://gemnasium.com/start-runner/codecov)

[Codecov](https://codecov.io/) task for [Start](https://github.com/start-runner/start).

## Install

```
npm i -D start-codecov
```

## Usage

Task is rely on LCOV report from [start-coverage](https://github.com/start-runner/coverage).

```js
// tasks.js
import Start from 'start';
import logger from 'start-simple-logger';
import clean from 'start-clean';
import files from 'start-files';
import mocha from 'start-mocha';
import * as coverage from 'start-coverage';
import codecov from 'start-codecov';
import istanbul from 'babel-istanbul';

const start = Start(logger());

export function cover() {
    return start(
        files('coverage/'),
        clean(),
        files('lib/**/*.js'),
        coverage.instrument(istanbul),
        files('test/**/*.js'),
        mocha(),
        coverage.report()
    );
}

export function travis() {
    return start(
        cover(),
        codecov()
    );
}
```

```js
// package.json
"scripts": {
  "task": "babel-node node_modules/.bin/start tasks",
  "cover": "npm run task cover",
  "travis": "npm run task travis"
}
```

## Arguments

`codecov(options)`

* `options` – [codecov options](https://github.com/codecov/codecov-node/blob/master/bin/codecov), `{ disable: 'search,gcov', file: 'coverage/lcov.info' }` by default<commit_msg>:pencil: update README<commit_after>[![npm](https://img.shields.io/npm/v/start-codecov.svg?style=flat-square)](https://www.npmjs.com/package/start-codecov)
[![travis](http://img.shields.io/travis/start-runner/codecov.svg?style=flat-square)](https://travis-ci.org/start-runner/codecov)
[![coverage](https://img.shields.io/codecov/c/github/start-runner/codecov.svg?style=flat-square)](https://codecov.io/github/start-runner/codecov)
[![deps](https://img.shields.io/gemnasium/start-runner/codecov.svg?style=flat-square)](https://gemnasium.com/start-runner/codecov)
[![gitter](https://img.shields.io/badge/gitter-join_chat_%E2%86%92-00d06f.svg?style=flat-square)](https://gitter.im/start-runner/start)

[Codecov](https://codecov.io/) task for [Start](https://github.com/start-runner/start).

## Install

```
npm i -D start-codecov
```

## Usage

```js
import Start from 'start';
import logger from 'start-simple-logger';
import files from 'start-files';
import clean from 'start-clean';
import mocha from 'start-mocha';
import * as coverage from 'start-coverage';
import codecov from 'start-codecov';
import istanbul from 'babel-istanbul';

const start = Start(logger());

export function cover() {
    return start(
        files('coverage/'),
        clean(),
        files('lib/**/*.js'),
        coverage.instrument(istanbul),
        files('test/**/*.js'),
        mocha(),
        coverage.report()
    );
}

export function travis() {
    return start(
        cover(),
        codecov()
    );
}
```

Task is rely on LCOV report from [start-coverage](https://github.com/start-runner/coverage).

See [documentation](https://github.com/start-runner/start#readme) for details.

## Arguments

`codecov(options)`

* `options` – [codecov options](https://github.com/codecov/codecov-node/blob/master/bin/codecov), `{ disable: 'search,gcov', file: 'coverage/lcov.info' }` by default
{'fraction_non_alphanumeric': 0.19185393258426967, 'fraction_numerical': 0.0025280898876404493, 'mean_word_length': 4.072649572649572, 'pattern_counts': {'":': 4, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 23, 'lorem ipsum': 0, 'www.': 2, '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': '1478710', 'n_tokens_mistral': 1259, 'n_tokens_neox': 1219, 'n_words': 203}