Search code examples
gitwebstorm

Webstorm uses wrong git user


I have right user.name and user.email in git config --global and --local. But when i try to push ro github, it tries to push with another user. As well, i have right data in VCS github settings, tested connection.

See no any other options or anything etc. for this.


Solution

  • The account used for pushing has nothing to do with user.name and user.email git settings.

    It will be the GitHub account if you are using an https url with your GitHub login, or your GitHub account if you are using ssh, and have registered your public key to that account.

    When you are pushing a git repo with Webstorm, you must check what url is registered to the remote name you are pushing to (like, for instance, origin)