How to sign out github account in vs code
Asked Answered
I

4

6

In VS code, I am signed in with a github account in which I have no longer my access. So I need to completely unlink the github account from vs code. How can I do that? I am using ubuntu.

Installment answered 15/12, 2020 at 17:31 Comment(0)
S
17

You can find this button at the bottom left corner:image

Selvage answered 15/12, 2020 at 18:24 Comment(2)
The option to sign out is now gone as of April 2022 from this menu.Sadism
So it is. 1.66.2 is missing the profile icon. Now what?Vicentevicepresident
D
3

Answer for VS Code version 1.76.2.

I was only able to sign out of my Github account by totally uninstalling Visual Studio Code and reinstalling it. It was a very quick process as I first made copies of (I'm on a mac):
~/Library/Application Support/Code/User/keybindings.json
~/Library/Application Support/Code/User/settings.json
and all extensions in
~/.vscode/extensions

The reason I needed this was I signed up for GitHub Copilot and was getting the error

Your GitHub token is invalid. Please sign out from your GitHub account using VSCode UI and try again.

but I could not figure out how to do this. I tried deleting all caches and anything with the name Github in it in:
~/Library/Application Support/Code
~/.vscode
but still this did not work and I had to resort to the nuclear option stated above.

After the fresh install I was successfully disconnected from my Github account and I was then able to get Copilot to authenticate correctly by signing in fresh to my Github account.

Diviner answered 24/3, 2023 at 17:23 Comment(1)
Thanks BigHeadCreations! This was my solution. Sad that it is not a priority to allow switching of accounts :-|Gebhardt
B
0

Without reinstalling I just changed the github account being used in vsode by first logging out of all github accounts in the default browser (maybe overriden in vsode settings).

Afterwards vscode with copilot extension allows a fresh login using the browser.

Buttercup answered 2/10 at 15:26 Comment(1)
Did not work for me (MacOS)Bruno
N
-1

If you have activitus extension on. Then it is possible that the user icon doesn't shows to you. Because it seems that the extension hide that icon. If this happen just go view>Apparence>Position of the activity bar and change the ocult option

Nika answered 16/5 at 20:6 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.