I\'ve started working with Android Studio and I found a problem when trying to connect to Github. I\'ve tried restarting Android Studio and even creating a new project, but I am
I got the issue solved by generating a token from https://github.com/settings/tokens and using it to add account option on Android Studio>File>settings>GitHub
you can install git in your operation system and use command for add your android project to github repository.
1- you should install git bash
2- open git bash in your project directory and initial it as a git repository
3- add your project to the local repository
4- commit your file to the local git repository
5- Create a branch, usually called a 'main' or 'master'
6- define remote git url
7- finally, you should push all your project into remote git repository
Updating to AndroidStudio 4.1.1 allowed me to access with my credentials without having to generate a token.
You have to check all required settings (see image GitHub settings required) at your GitHub account at https://github.com/settings/tokens/, and then you have to update the token (You must regenerate your token if you havent copied yet).... Then you can insert your credentials again in Android Studio and... ¡ready!
You can use the Project from Version Control, it has git.
What I did was I logged in through a token, it also tells you what needs to be added to the token and that worked for me.
You can create the token here: https://github.com/settings/tokens