atom / github

:octocat: Git and GitHub integration for Atom
https://github.atom.io
MIT License
1.12k stars 393 forks source link

Can not log out or switch user to push updated files #1693

Open ghost opened 6 years ago

ghost commented 6 years ago

@cryptopool-builders commented on Sep 14, 2018, 10:22 PM UTC:

Description

I was initially using Atom with my personal github account and had no issues pushing files. I am now using my business github account and when trying to push the changes I get an error message remote: Repository not found.

I am assuming this is due to the fact the on the Git tab Atom is logged in with my old account information.

I have tried uninstalling Atom and deleting every dang atom folder that I can find on my PC. And I have tried various suggestions on other tickets and it will not log me out.

I am on windows 10 and using version 1.30.0

This issue was moved by rsese from atom/atom#18055.

rsese commented 6 years ago

Thanks for the report - the GitHub package uses whatever credential helper you're using on your system so I'm guessing you have the same problem from the command line?

You can edit/delete your saved credentials on Windows in Credential Manager under Windows Credentials > Generic Credentials I believe. Do you see any github.com entries there?

smashwilson commented 6 years ago

You can also run the GitHub: Logout command from your command palette to clear the credentials you've used in the GitHub pane, although you will also need to follow @rsese's instructions too to clear your token from git's cached credentials.

mcanepa commented 5 years ago

I've just login in github using atom (not my pc) then wanted to logout and didn't find a button to do so.

I think than and exit action must be present somewhere in order to blank own credentials.

mvuksanovic commented 5 years ago

I did it by going to https://github.com/settings/applications and revoke authorisation for Atom.

T-T-dev commented 4 years ago

Hi guys,

I have the same need - I would like to switch between several accounts, my personal and my employer's accounts. I did what mvuksanovic suggested but it only partially worked for me - I was successfully able to create a repository under the correct account. However, it was created by my past log-in. I have done everything short of a fresh atom installation, since that is not a feasible solution for me anyway as I need to do this on a daily basis. OP - have you found a work around this yet?

T-T-dev commented 4 years ago

... so a bit more information on my issues - I hope it helps others. I am able to change the credentials correctly in the "GitHub" tab within Atom, but not the "Git" tab. I have attached screenshots of both tabs - you can see by the logo that the both tabs have different users logged in - pretty sure that is our problem.

Screen Shot 2020-03-29 at 7 40 25 PM Screen Shot 2020-03-29 at 7 40 14 PM
T-T-dev commented 4 years ago

Hello again everybody, I resolved this by doing the following -

  1. Open Platformio IDE terminal
  2. type the following (obviously change the username ) ----> git config --global user.name "YOUR_USERNAME"
  3. then type the following (obviously change the email ) ----> git config --global user.email "YOUR_EMAIL_ADDRESS"
  4. Close Atom and re-open, and your GIT tab should have switched.

... the above only takes care of the Git tab, now for the GitHub tab.

  1. go to GitHub.com, revoke Atom from the account you wish to remove from Atom, and log out
  2. log into GitHub.com from the account you wish to work with.
  3. In Atom, under the github tab, log in and get a new token.

I do the above 7 steps every time I want to switch between business and work and personal accounts. Somewhat cumbersome, but works for me.

credit - I found the above information here: https://courses.cs.washington.edu/courses/cse154/19su/resources/assets/atomgit/macosx/

smashwilson commented 4 years ago

... the above only takes care of the Git tab, now for the GitHub tab.

Does the GitHub: Logout command not work for you?

T-T-dev commented 4 years ago

The "GitHub: Logout" only successfully logs me out of GitHub, but does not reset the credentials under the Git tab, like this --->

Git_vs_gitHub_tabs

When I made a commit with those two log-ins mismatched, I committed to my personal repository from my work account.

smashwilson commented 4 years ago

2428 should help manage your git identity (the user.name and user.email config settings that git uses in the metadata of commits you create).

Notice that this is different than:

You usually want these three "accounts" to match, but they don't necessarily, and the last one is partially managed outside of Atom's visibility in a way that's hard to sync. I'd love to have a solution that better communicates this.

If anyone else would like to explore an idea to solve this, I'd encourage you to open a feature request to fully think it out :smile:

pbrady32 commented 4 years ago

Hey guys,

I'm having the same problem and it's driving me crazy. I followed all of the steps listed in @T-T-dev post, deleted the gitlab credentials from Windows Credential Manager, used the GitHub: Logout command, and restarted my computer.

The Git window shows the right account thanks to T-T, but I cannot for the life of me get the right account to show on the GitHub window.

Has anyone solved this for Windows 10 on Atom 1.48.0?

rst-mnk commented 2 years ago

go in github settings and in authentication tab remove acess permission of atom tocken.

go in file>settings>packages in core packages find github and disable it and then enable.

now atom will ask again to login in github.