Reputation: 417
I want to be able to use the GitHub integration in Android Studios. I've made a project and I've done all the login-stuff you need to do in order to connect to your GitHub-account.
In Android Studios, I click on VCS -> Import Into Version Control -> Share Project on GitHub.
Following question comes up:
Project is already on GitHub
Can't connect to repository from configured remote. You could want to check .git config.
Do you want to proceed anyway?
If I click 'Yes', I can continue to fill in a new repository and description.
I get the following warning:
"Can't add remote fatal: remote github already exists. during executing git -c core.quotepath=false remote add github https://github.com/Wickerman2/Test2.git"
But I don't have any repositories! Android Studios only creates the repository Test2 and won't push any files!
Upvotes: 2
Views: 15676
Reputation: 1337
The cleanest way to do it is the following:
Now you should be able to use the version control.
Upvotes: 1
Reputation: 19351
It seems to be that you created a remote repository before you wanted to share it on Github.
I see two ways:
VCS -> Git -> Push
Share a project
.git
folder. On Linux press Ctrl+H
to show hidden files and copy this folder to your project.
At this time, just commit changes and push it to remote repository.Show hidden files on Windows: http://www.technipages.com/show-hidden-files-windows
If you would like to learn a bit Git console, visit: https://try.github.io/levels/1/challenges/1
Already I more times use console than Android Studio Github Integration, cause the second ones sometimes freezes and cannot force some actions.
Upvotes: 3