5 var persistence = require('gitter-web-persistence');
6 var checkRepoPrivacy = require('../server/services/check-repo-privacy');
8 var Promise = require('bluebird');
10 var opts = require('yargs')
15 description: 'Maximum count'
18 .alias('help', 'h').argv;
22 console.error(error.stack);
26 persistence.Troupe.where('githubType', 'REPO')
27 .sort({ dateLastSecurityCheck: 1 })
30 .then(function(repos) {
32 repos.map(function(repo) {
33 return checkRepoPrivacy(repo.uri);
40 .catch(function(err) {