# diffsvn2git

> Nodejs lib to convert a svn commit to a git diff.

Latest version **0.1.1** (published 2017-08-08) · MIT license · 0 weekly downloads

## Install

```sh
npm install diffsvn2git
pnpm add diffsvn2git
yarn add diffsvn2git
bun add diffsvn2git
```

## Health

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

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.1.1 |
| Published | 2017-08-08 |
| First published | 2017-04-24 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 5 |
| Known vulnerabilities | 0 (+1 in 1 direct dependencies) |
| Install scripts | no |
| GitHub stars | 3 |
| Author | Nícolas Ferreira |
| Maintainers | nickrfer |
| Keywords | nodejs, svn, git, diff |

## Links

- npm: https://www.npmjs.com/package/diffsvn2git
- Repository: https://github.com/nickrfer/diffsvn2git
- Homepage: https://github.com/nickrfer/diffsvn2git#readme
- Issues: https://github.com/nickrfer/diffsvn2git/issues
- npm.io page: https://npm.io/package/diffsvn2git

## Dependencies (5)

- [async](https://npm.io/package/async.md) ^2.4.1
- [xml2js](https://npm.io/package/xml2js.md) ^0.4.17
- [svn-spawn](https://npm.io/package/svn-spawn.md) ^0.1.5
- [dateformat](https://npm.io/package/dateformat.md) ^2.0.0
- [easy-spawn](https://npm.io/package/easy-spawn.md) 0.0.2

## Recent versions

- 0.1.1 (latest) — 2017-08-08
- 0.1.0 — 2017-06-18
- 0.0.26 — 2017-06-18
- 0.0.25 — 2017-06-14
- 0.0.24 — 2017-06-14
- 0.0.23 — 2017-06-14
- 0.0.22 — 2017-06-14
- 0.0.21 — 2017-06-11
- 0.0.20 — 2017-06-11
- 0.0.19 — 2017-06-08
- 0.0.17 — 2017-04-27
- 0.0.16 — 2017-04-26
- 0.0.15 — 2017-04-25
- 0.0.14 — 2017-04-25
- 0.0.13 — 2017-04-25
- … 2 more at https://npm.io/package/diffsvn2git/versions

## README

# diffsvn2git

[![Codacy Code Badge](https://api.codacy.com/project/badge/grade/ddb909b3f3ba4b21a20b8de2ae972215)](https://www.codacy.com/app/diffsvn2git)
[![Codacy Coverage Badge](https://api.codacy.com/project/badge/coverage/ddb909b3f3ba4b21a20b8de2ae972215)](https://www.codacy.com/app/nickrfer/diffsvn2git)
[![Circle CI](https://circleci.com/gh/nickrfer/diffsvn2git.svg?style=svg)](https://circleci.com/gh/nickrfer/diffsvn2git)
[![Dependency Status](https://dependencyci.com/github/nickrfer/diffsvn2git/badge)](https://dependencyci.com/github/nickrfer/diffsvn2git)

[![Dependency Status](https://david-dm.org/nickrfer/diffsvn2git.svg)](https://david-dm.org/nickrfer/diffsvn2git)
[![devDependency Status](https://david-dm.org/nickrfer/diffsvn2git/dev-status.svg)](https://david-dm.org/nickrfer/diffsvn2git#info=devDependencies)

[![npm](https://img.shields.io/npm/v/diffsvn2git.svg)](https://www.npmjs.com/package/diffsvn2git)
[![Stories in Ready](https://badge.waffle.io/nickrfer/diffsvn2git.png?label=ready&title=Ready)](https://waffle.io/nickrfer/diffsvn2git)
[![Join the chat at https://gitter.im/diffsvn2git/Lobby](https://badges.gitter.im/diffsvn2git/Lobby.svg)](https://gitter.im/diffsvn2git/Lobby?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
[![npm](https://img.shields.io/npm/l/diffsvn2git.svg)]()


Nodejs lib to convert a svn commit revision to a git diff.

[![NPM](https://nodei.co/npm/diffsvn2git.png?downloads=true&downloadRank=true&stars=true)](https://nodei.co/npm/diffsvn2git/)

## Distribution

* [Node Module](https://www.npmjs.org/package/diffsvn2git)

## Usage

* initialization

```javascript
var DiffSvn2Git = require('diffsvn2git');
var diffSvn2Git = new DiffSvn2Git({
    // these parameters will be used by the svn spawn dependency.
    cwd: '/svn/awesome-repo/awesome-repo',
    username: 'awesome-user', // optional if authentication not required or is already saved
    password: 'pass', // optional if authentication not required or is already saved
    noAuthCache: true // optional, if true, username does not become the logged in user on the machine
});
```

* listRevisionsByDate (work in progress)
> Lists all the revision information by date in JSON format.
```
diffSvn2Git.listRevisionsByDate().then((revJson) => {
    console.log(revJson);
});
```

* parse
> The parse method reads the repository and generates a git diff from the revision passed, or the last commit's revision. if the revision parameter is not passed to the method.
```
diffSvn2Git.parse().then((patch) => {
    console.log(patch);
});
```

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