Sreejith
Sreejith

Reputation: 39

How can I change the default credentials for Git commit?

I am committing code using TortoiseGit, but I do not have access to the git repository which am committing I want to use other persons username and password to commit.

Each time I commit, the commit did not happen because it tries to commit using my credential (Current logged in win user).

I want to give the other persons id and password to commit.
How is it possible?

Upvotes: 1

Views: 800

Answers (1)

VonC
VonC

Reputation: 1323553

A commit is done locally, and uses local config (user.name/user.email) which have nothing to do with the authentication used when pushing to a remote repo.

So if you are talking about pushing, check your remote url (git remote -v): if it is https and Git does not ask you for credential, you probably have a credential helper caching those.

Upvotes: 1

Related Questions