Why does git log show my password?

Viewed 2043

When I type git log the resulting list of commits show my password in brackets <> after my username, like this:

commit 5ff14f929e2244f388a41b6f711e7b9b58c57cb2
Author: herman <MyPassw0rd>
Date:   Wed Aug 29 10:00:39 2018 +0200

initial commit 

Why does it do this, and how do I fix it?

1 Answers

That's not supposed to be your password, it should be your email. While I have no idea how you entered your password into the email setting, you can set your email in the current project using

git config user.email "email@example.com"

or globally using

git config --global user.email "email@example.com"

Also, you should likely change your password.

Related