# clean-git-ref

> Clean an input string into a usable git ref

Latest version **2.0.1** (published 2019-01-18) · Apache-2.0 license · 0 weekly downloads

## Install

```sh
npm install clean-git-ref
pnpm add clean-git-ref
yarn add clean-git-ref
bun add clean-git-ref
```

## Health

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

Positive: has types package; no vulnerabilities; high quality score.

Warnings: low downloads; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 2.0.1 |
| Published | 2019-01-18 |
| First published | 2016-04-04 |
| Weekly downloads | 0 |
| License | Apache-2.0 |
| TypeScript types | separate (@types/clean-git-ref) |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 2.3 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 4 |
| Author | Eli White |
| Maintainers | eliwhite |

## Links

- npm: https://www.npmjs.com/package/clean-git-ref
- Repository: https://github.com/TheSavior/clean-git-ref
- Homepage: https://github.com/TheSavior/clean-git-ref#readme
- Issues: https://github.com/TheSavior/clean-git-ref/issues
- npm.io page: https://npm.io/package/clean-git-ref

## Recent versions

- 2.0.1 (latest) — 2019-01-18
- 1.0.3 — 2016-04-04
- 1.0.2 — 2016-04-04
- 1.0.1 — 2016-04-04

## README

# clean-git-ref

[![Build Status](https://travis-ci.org/TheSavior/clean-git-ref.svg)](https://travis-ci.org/TheSavior/clean-git-ref)

Clean an input string into a usable git ref. 

For more reference, read https://git-scm.com/docs/git-check-ref-format

## Installation

```sh
$ npm install clean-git-ref --save-dev
```

## API Usage

### clean(string input) -> string output
```
var cleanGitRef = require('clean-git-ref');

assert.strictEqual(cleanGitRef.clean('bad git ref formats/'), 'bad-git-ref-formats');
```

---
_Source: https://npm.io/package/clean-git-ref · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
