第一步:打开Android studio 测试 git
File->Settings->Version Control(展开)->git
第二步:测试github
File->Settings->Version Control(展开)->GitHub
第三步:直接上传工程到github
VCS->Import into Version Control->Share Project on GitHub
OK,可以去github查看你的结果了!!!
参考:
https://blog.csdn.net/hebbely/article/details/79103485
https://www.cnblogs.com/imqsl/p/6763133.html
如何解决failed to push some refs to git
可以通过如下命令进行代码合并【注:pull=fetch+merge]
git pull --rebase origin master
此时再执行语句 git push -u origin master即可完成代码上传到github
错误:
上午 11:03 Can't finish GitHub sharing process
Successfully created project 'MyApplication' on GitHub, but initial commit failed:
unable to auto-detect email address (got 'Administrator@YR160806-KUPA.(none)')
原因:没有配置github
配置一下,删除GitHub上的仓库,重新上传就好了