How do I clone into a non-empty directory?

前端 未结 16 1489
庸人自扰
庸人自扰 2020-11-22 06:20

I have directory A with files matching directory B. Directory A may have other needed files. Directory B is a git repo.

I want to clone directory B to directory A bu

16条回答
  •  遇见更好的自我
    2020-11-22 06:41

    Maybe I misunderstood your question, but wouldn't it be simpler if you copy/move the files from A to the git repo B and add the needed ones with git add?

    UPDATE: From the git doc:

    Cloning into an existing directory is only allowed if the directory is empty.

    SOURCE: http://git-scm.com/docs/git-clone

提交回复
热议问题