github-current-user
Get the current GitHub user and verify that they have access to a private key
that's been authorized to that account.
Uses the username in user.username or the email address in user.email of
the user's .gitconfig and the private keys in in the user's ssh-agent with
fallback to ~/.ssh/id_rsa or ~/.ssh/id_dsa.
example
var user = require('github-current-user');
user.verify(function (err, verified, username) {
console.log(verified, username);
});
test out on the cli
$ npm i github-current-user -g
$ github-current-user
You are verified as maxogden