Logout and login as another user git bash

I want to logout from Git bash and login it again as another user .

I have googled but can’t find any solution.

  • Should checkins be small steps or complete features?
  • cherry-picking with git with a conflict
  • Git with centralized workflow
  • Why does git revert delete files on my filesystem?
  • Git: List all files in a directory across all branches?
  • python manage.py collectstatic --noinput error when deploying Django project to Heroku
  • A true, robust, git svn externals solution?
  • Git Error: unable to find
  • Jenkins + Git plugin CheckoutConflictException
  • hg equivalent of git notes
  • Bitbucket branch management
  • Is it worth the effort to create pretty revision history in a DVCS?
  • 2 Solutions collect form web for “Logout and login as another user git bash”

    You don’t have to “logout” or “login”: regarding git, who you are is determined by:

    git config user.name
    git config user.email
    

    Change those two settings while being in a repo, and you are someone else, when it comes to creating commits.

    That has nothing to do with git remote -v, that is with the user account you will use to push to the upstream repo.

    • for an https url, you can simply specify a new user
    • for ssh, you would need a ~/.ssh/config file referring to multiple private ssh keys (also described here).

    use

    git config --global user.name [Your User name]
    
    git config --global user.email [Your Email]
    
    Git Baby is a git and github fan, let's start git clone.