paulirish / github-email

Get a GitHub user's email. :sunglasses: Use this responsibly.
https://www.npmjs.com/package/github-email
998 stars 111 forks source link

github-email

Retrieve a GitHub user's email even if it's not public. Pulls info from Github user, NPM, activity commits, owned repo commit activity.

image

install

npm install --global github-email

use

github-email ghusername

Authenication Token

If the GH_EMAIL_TOKEN environment variable is not set, the script will ask the user to generate a personal access token for authentication. To do this:

  1. Visit https://github.com/settings/tokens/new?description=github-email
  2. Keep the checkboxes all unchecked
  3. Click Generate Token.
  4. Copy the token.
  5. Run this in your shell export GH_EMAIL_TOKEN=<token>
  6. Also add that line to your shell configuration (e.g. .bashrc)