I am trying to push android project to private empty repo with android studio . But I cannot find simple solution. How can I do this ?
相关问题
- Could not read entry … from cache taskArtifacts.bi
- How to add working directory to deployment in GitH
- Why does recursive submodule update from github fa
- Extended message for commit via Visual Studio Code
- Non-static method isGooglePlayServicesAvailable an
相关文章
- 请教Git如何克隆本地库?
- java开发bug问题:GitHub授权登录无法获取授权账号信息?
- Is there a Github markdown language identifier for
- “no implicit conversion of Integer into String” er
- GitHub:Enterprise post-receive hook
- Git Clone Fails: Server Certificate Verification F
- Android virtual device manager crashes with “doubl
- SSIS solution on GIT?
If you are pushing to a private repo in a local location ie. a private server.:
Assuming you have set up local git repository, cd into the remote location and clone your local repository with
git clone 'path to local repo'
cloning will set the local repo as a remote, so we have to remove that with
git remote remove origin
make the remote repo bare with
git config --bool core.bare true
Then in your local repository add the remote with
git remote add origin 'location to remote git repo'
Now you should be able to push to remote in Android studio.
Github helpfully provides a guide for adding an existing code base into a repository which already exists, here. Whilst not specific to android studio, it will allow you to use whatever normal commit method you use.
In a nutshell:
git init
git add .
git commit -m "your commit message"
git remote add origin your@git:repo/name
git remote -v
git push origin master