Git cli: get user info from username

cwhelms picture cwhelms · Sep 26, 2011 · Viewed 128.7k times · Source

Is there a way to get the name of the user, given only their username?

Something like this output git show <username> (I know this doesn't work)

username: username
name: First Last
email: email@address

I know I can do this with a GitHub api call, but would prefer to keep it within the CLI.

Answer

NewPersona picture NewPersona · May 16, 2013
git config user.name
git config user.email

I believe these are the commands you are looking for.

Here is where I found them: http://alvinalexander.com/git/git-show-change-username-email-address