Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

getcontributors

Package Overview
Dependencies
Maintainers
1
Versions
95
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

getcontributors - npm Package Compare versions

Comparing version 1.0.0 to 1.0.1

28

out/lib/getcontributors.js

@@ -5,5 +5,9 @@ // Generated by CoffeeScript 1.4.0

module.exports = function(opts, next) {
var balUtil, contributorFeeds, contributors, feedr, tasks, user, _i, _len, _ref, _ref1;
var TaskGroup, balUtil, contributorFeeds, contributors, eachr, extendr, feedr, tasks, typeChecker, user, _i, _len, _ref, _ref1;
feedr = new (require('feedr').Feedr);
balUtil = require('bal-util');
eachr = require('eachr');
extendr = require('extendr');
TaskGroup = require('taskgroup').TaskGroup;
typeChecker = require('typeChecker');
_ref = balUtil.extractOptsAndCallback(opts, next), opts = _ref[0], next = _ref[1];

@@ -14,3 +18,5 @@ contributors = {};

}
tasks = new balUtil.Group(function(err) {
tasks = new TaskGroup().setConfig({
concurrency: 0
}).once('complete', function(err) {
var contributorName, contributorsNames, contributorsSorted;

@@ -50,7 +56,7 @@ if (err) {

feedr.readFeeds(contributorFeeds, function(err, feedRepos) {
balUtil.each(feedRepos, function(repos) {
return balUtil.each(repos, function(repo) {
eachr(feedRepos, function(repos) {
return eachr(repos, function(repo) {
var packageUrl;
packageUrl = repo.html_url.replace('//github.com', '//raw.github.com') + '/master/package.json';
return tasks.push(function(complete) {
return tasks.addTask(function(complete) {
return feedr.readFeed(packageUrl, function(err, packageData) {

@@ -72,3 +78,3 @@ var contributor, contributorData, contributorId, contributorMatch, usernameMatch, _base, _j, _len1, _ref2, _ref3, _ref4;

};
if (balUtil.isString(contributor)) {
if (typeChecker.isString(contributor)) {
contributorMatch = /^([^<(]+)\s*(?:<(.+?)>)?\s*(?:\((.+?)\))?$/.exec(contributor);

@@ -78,3 +84,3 @@ if (!contributorMatch) {

}
balUtil.extend(contributorData, {
extendr.extend(contributorData, {
name: (contributorMatch[1] || '').trim() || null,

@@ -85,4 +91,4 @@ email: (contributorMatch[2] || '').trim() || null,

});
} else if (balUtil.isPlainObject(contributor)) {
balUtil.extend(contributorData, {
} else if (typeChecker.isPlainObject(contributor)) {
extendr.extend(contributorData, {
name: contributor.name || null,

@@ -122,3 +128,3 @@ email: contributor.email || null,

}
balUtil.safeShallowExtendPlainObjects(contributors[contributorId], contributorData);
extendr.safeShallowExtendPlainObjects(contributors[contributorId], contributorData);
contributors[contributorId].repos[repo.name] = repo.html_url;

@@ -131,5 +137,5 @@ }

});
return tasks.async();
return tasks.run();
});
return this;
};
{
"name": "getcontributors",
"version": "1.0.0",
"version": "1.0.1",
"description": "Fetch the contributors of the repositories of the specified github users",

@@ -27,3 +27,7 @@ "homepage": "https://github.com/bevry/getcontributors",

"dependencies": {
"bal-util": "~1.16.11",
"bal-util": "~2.0.0",
"extendr": "~2.0.1",
"taskgroup": "~3.1.2",
"eachr": "~2.0.2",
"typechecker": "~2.0.1",
"feedr": "~2.4.2"

@@ -33,3 +37,4 @@ },

"coffee-script": "~1.4.0",
"joe": "~1.1.1",
"joe": "~1.2.0",
"joe-reporter-console": "~1.2.1",
"chai": "~1.5.0"

@@ -41,5 +46,5 @@ },

"scripts": {
"test": "node ./out/test/everything-test.js --joe-reporter=list"
"test": "node ./out/test/everything-test.js"
},
"main": "./out/lib/getcontributors.js"
}

@@ -1,3 +0,7 @@

# Get Contributors [![Build Status](https://secure.travis-ci.org/bevry/getcontributors.png?branch=master)](http://travis-ci.org/bevry/getcontributors)
# Get Contributors
[![Build Status](https://secure.travis-ci.org/bevry/getcontributors.png?branch=master)](http://travis-ci.org/bevry/getcontributors)
[![NPM version](https://badge.fury.io/js/getcontributors.png)](https://npmjs.org/package/getcontributors)
[![Flattr this project](https://raw.github.com/balupton/flattr-buttons/master/badge-89x18.gif)](http://flattr.com/thing/344188/balupton-on-Flattr)
Fetch the contributors of the repositories of the specified github users

@@ -18,4 +22,4 @@

users: ['bevry'],
github_client_id: null,
github_client_secret: null,
github_client_id: null, // optional
github_client_secret: null, // optional
log: console.log, // args: level, message...

@@ -28,14 +32,16 @@ next: console.log // args: err, contributors

``` coffee
``` javascript
{
name: "Benjamin Lupton"
email: "b@lupton.cc"
url: "https://github.com/balupton"
username: "balupton"
text: "Benjamin Lupton <b@lupton.cc> (https://github.com/balupton)"
name: "Benjamin Lupton",
email: "b@lupton.cc",
url: "https://github.com/balupton",
username: "balupton",
text: "Benjamin Lupton <b@lupton.cc> (https://github.com/balupton)",
repos: {
docpad: 'https://github.com/bevry/docpad'
getcontributors: 'https://github.com/bevry/getcontributors'
docpad: "https://github.com/bevry/docpad",
getcontributors: "https://github.com/bevry/getcontributors"
// ...
}
}
```

@@ -50,3 +56,3 @@

Licensed under the [MIT License](http://creativecommons.org/licenses/MIT/)
<br/>Copyright &copy; 2012+ [Bevry Pty Ltd](http://bevry.me)
Licensed under the incredibly [permissive](http://en.wikipedia.org/wiki/Permissive_free_software_licence) [MIT License](http://creativecommons.org/licenses/MIT/)
<br/>Copyright &copy; 2012 [Bevry Pty Ltd](http://bevry.me)
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc