<commit_before># Guide: CI Setup

Enforce commit conventions with confidence by linting on your CI servers with `commitlint`.

 We'll use TravisCI for this guide but the principles are valid for any CI server.

## Install

```bash
# Create a git repository if needed
git init

# Create a package.json if needed
npm init

# Install and configure if needed
npm install --save-dev @commitlint-{cli,angular}
echo "module.exports = {extends: ['@commitlint/config-angular']};" > commitlint.config.js
```

## First test run with Travis

Add a `.travis.yml` to your project root

```yaml
# .travis.yml
language: node_js
before_install: git fetch --unshallow
script:<commit_msg>docs: fix incorrect package names<commit_after># Guide: CI Setup

Enforce commit conventions with confidence by linting on your CI servers with `commitlint`.

 We'll use TravisCI for this guide but the principles are valid for any CI server.

## Install

```bash
# Create a git repository if needed
git init

# Create a package.json if needed
npm init

# Install and configure if needed
npm install --save-dev @commitlint/{config-angular,cli}
echo "module.exports = {extends: ['@commitlint/config-angular']};" > commitlint.config.js
```

## First test run with Travis

Add a `.travis.yml` to your project root

```yaml
# .travis.yml
language: node_js
before_install: git fetch --unshallow
script:
{'fraction_non_alphanumeric': 0.0967032967032967, 'fraction_numerical': 0.0, 'mean_word_length': 4.5528455284552845, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, 'https://': 0, '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': '2847112', 'n_tokens_mistral': 427, 'n_tokens_neox': 397, 'n_words': 171}