parse-diff
Advanced tools
Comparing version 0.0.12 to 0.0.13
@@ -9,3 +9,3 @@ (function() { | ||
module.exports = function(input) { | ||
var add, chunk, del, file, files, from_file, index, line, lines, ln_add, ln_del, new_file, noeol, normal, parse, restart, schema, start, to_file, _i, _len; | ||
var add, chunk, del, deleted_file, file, files, from_file, index, line, lines, ln_add, ln_del, new_file, noeol, normal, parse, restart, schema, start, to_file, _i, _len; | ||
if (!input) { | ||
@@ -42,2 +42,6 @@ return []; | ||
}; | ||
deleted_file = function() { | ||
restart(); | ||
return file.deleted = true; | ||
}; | ||
index = function(line) { | ||
@@ -95,3 +99,3 @@ restart(); | ||
}; | ||
schema = [[/^diff\s/, start], [/^new file mode \d+$/, new_file], [/^index\s[\da-zA-Z]+\.\.[\da-zA-Z]+(\s(\d+))?$/, index], [/^---\s/, from_file], [/^\+\+\+\s/, to_file], [/^@@\s+\-(\d+),(\d+)\s+\+(\d+),(\d+)\s@@/, chunk], [/^-/, del], [/^\+/, add]]; | ||
schema = [[/^diff\s/, start], [/^new file mode \d+$/, new_file], [/^deleted file mode \d+$/, deleted_file], [/^index\s[\da-zA-Z]+\.\.[\da-zA-Z]+(\s(\d+))?$/, index], [/^---\s/, from_file], [/^\+\+\+\s/, to_file], [/^@@\s+\-(\d+),(\d+)\s+\+(\d+),(\d+)\s@@/, chunk], [/^-/, del], [/^\+/, add]]; | ||
parse = function(line) { | ||
@@ -98,0 +102,0 @@ var m, p, _i, _len; |
require('coffee-script/register'); | ||
module.exports = require('./parse'); |
{ | ||
"name": "parse-diff", | ||
"version": "0.0.12", | ||
"version": "0.0.13", | ||
"description": "Unified diff parser", | ||
@@ -17,8 +17,9 @@ "author": "Sergey Todyshev <stodyshev@gmail.com>", | ||
"contributors": [ | ||
"Sergey Todyshev <stodyshev@gmail.com>" | ||
"Sergey Todyshev <stodyshev@gmail.com>", | ||
"Scott Christopherson <scott@scott-christopherson.com>" | ||
], | ||
"dependencies": { | ||
"coffee-script": "~1.7", | ||
"underscore": "~1.6", | ||
"underscore.string": "~2.3" | ||
"coffee-script": "~1.8", | ||
"underscore": "~1.7", | ||
"underscore.string": "~2.4" | ||
}, | ||
@@ -35,3 +36,3 @@ "devDependencies": { | ||
"expect.js": "~0.3", | ||
"grunt-contrib-coffee": "~0.10.1" | ||
"grunt-contrib-coffee": "~0.12" | ||
}, | ||
@@ -38,0 +39,0 @@ "scripts": { |
[![Built with Grunt](https://cdn.gruntjs.com/builtwith.png)](http://gruntjs.com/) | ||
[![Build Status](https://drone.io/github.com/sergeyt/parse-diff/status.png)](https://drone.io/github.com/sergeyt/parse-diff/latest) | ||
[![Deps Status](https://david-dm.org/sergeyt/parse-diff.png)](https://david-dm.org/sergeyt/parse-diff) | ||
[![DevDeps Status](https://david-dm.org/sergeyt/parse-diff/dev-status.png)](https://david-dm.org/sergeyt/parse-diff#info=devDependencies) | ||
[![NPM version](https://badge.fury.io/js/parse-diff.png)](http://badge.fury.io/js/parse-diff) | ||
[![NPM](https://nodei.co/npm/parse-diff.png?downloads=true&stars=true)](https://nodei.co/npm/parse-diff/) | ||
@@ -10,0 +7,0 @@ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
16912
133
26
+ Addedcoffee-script@1.8.0(transitive)
+ Addedunderscore@1.7.0(transitive)
+ Addedunderscore.string@2.4.0(transitive)
- Removedcoffee-script@1.7.1(transitive)
- Removedunderscore@1.6.0(transitive)
- Removedunderscore.string@2.3.3(transitive)
Updatedcoffee-script@~1.8
Updatedunderscore@~1.7
Updatedunderscore.string@~2.4