简体   繁体   English

我可以使用本地存储库作为git远程服务器吗

[英]Can I use a local repository as a git remote

I have two repositories locally, A and B. Can I use the local copy of A, as a remote in B? 我在本地有两个存储库,即A和B。能否将A的本地副本用作B中的远程数据库?

Something like 就像是

git remote add A file:///path/to/repo/

是的,就像魅力一样。

git remote add A file:///path/to/repo/

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 Git:创建了本地和远程存储库,如何使用推送到远程存储库的文件? - Git: Created a local and remote repositories, how can I use the files I pushed to the remote repository? 我可以克隆远程git存储库,但可以引用本地存储库以提高效率吗? - Can I clone a remote git repository but reference a local repository for efficiency? 我可以创建一个带有本地存储库的远程 git 存储库吗? - Can I create a remote git repository with a local repository inside? 我可以使用同一存储库的远程.git替换本地.git吗? - Can I replace my local .git with a remote .git for the same repository? 如何删除本地git存储库中的远程分支? - How can I delete a remote branch in a local git repository? 如何将本地无版本代码与git远程存储库相关联? - How can I associate local unversioned code to git remote repository? 为什么我不能将此远程GitHub存储库添加为本地GIT存储库? - Why I can't add this remote GitHub repository to my local GIT repository as remote? 远程和本地git存储库 - Remote and local git repository 我的朋友可以使用我本地的 git 存储库作为他的远程存储库吗? - Can my friend use my local git repository as his remote repository? 我可以使用'git -m'来更改远程存储库吗? - Can I use 'git -m ' to change the remote repository?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM