UNPKG

ghteams

Version:

Interact with the GitHub organisation teams API

14 lines (10 loc) 511 B
const ghauth = require('../ghauth') , ghteams = require('./') ghauth({ configName: 'nodejs', scopes: [ 'read:org' ] }, function (err, authData) { if (err) throw err ghteams.list(authData, 'nodejs', function (err, teamlist) { if (err) throw err console.log(teamlist.map(function (t) { return { id: t.id, slug: t.slug, desc: t.description } })) console.log(teamlist.filter(function (t) { return !/^iojs-/.test(t.slug) }).map(function (t) { return `@nodejs/${t.slug}` }).join(', ')) }) })