normalize-package-data
Advanced tools
Comparing version 0.2.1 to 0.2.2
@@ -30,2 +30,5 @@ var semver = require("semver") | ||
r = ghurl.replace(/^https?:\/\//, 'git://') | ||
} else if (/^[\w-]+\/[\w-]+$/.test(r)) { | ||
// repo has 'user/reponame' filled in as repo | ||
data.repository.url = "git://github.com/" + r | ||
} | ||
@@ -32,0 +35,0 @@ } |
{ | ||
"name": "normalize-package-data", | ||
"version": "0.2.1", | ||
"version": "0.2.2", | ||
"author": "Meryn Stol <merynstol@gmail.com>", | ||
@@ -5,0 +5,0 @@ "description": "Normalizes data that can be found in package.json files.", |
@@ -52,3 +52,3 @@ # normalize-package-data [![Build Status](https://travis-ci.org/meryn/normalize-package-data.png?branch=master)](https://travis-ci.org/meryn/normalize-package-data) | ||
When `private` field is set to `true`, no warnings will be generated. | ||
When `private` field is set to `true`, warnings will be suppressed. | ||
@@ -55,0 +55,0 @@ ### Potential exceptions |
@@ -132,2 +132,16 @@ var tap = require("tap") | ||
tap.test("treat visionmedia/express as github repo", function(t) { | ||
var d = {repository: {type: "git", url: "visionmedia/express"}} | ||
normalize(d) | ||
t.same(d.repository, { type: "git", url: "git://github.com/visionmedia/express" }) | ||
t.end() | ||
}); | ||
tap.test("treat isaacs/node-graceful-fs as github repo", function(t) { | ||
var d = {repository: {type: "git", url: "isaacs/node-graceful-fs"}} | ||
normalize(d) | ||
t.same(d.repository, { type: "git", url: "git://github.com/isaacs/node-graceful-fs" }) | ||
t.end() | ||
}); | ||
tap.test('no new globals', function(t) { | ||
@@ -134,0 +148,0 @@ t.same(Object.keys(global), globals) |
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
44745
1223