“ git subtree add”失败,并显示“ Unlink of file”

时间:2019-02-08 11:22:17

标签: git git-subtree

我们想离开子模块,尝试使用子树系统。

我们有两个存储库:

Qt-Integration
 - UEPlugin

Cos-Sim
 - CosmetologyTrainer

我想将 Qt-Integration / UEPlugin 作为子树添加到 Plugins / Qt

Cos-Sim / CosmetolgyTrainer
my@DESKTOP-I1D3N52 MINGW64 /c/my/5vid/Test/Cos-Sim(CosmetologyTrainer)
$ git subtree add --prefix=Plugins/Qt --squash git@github.com:5Vid/Qt-Integration.git UEPlugin
git fetch git@github.com:5Vid/Qt-Integration.git UEPlugin
From github.com:5Vid/Qt-Integration
 * branch            UEPlugin   -> FETCH_HEAD
Unlink of file 'Plugins' failed. Should I try again? (y/n)

但是我得到取消链接文件...

在浏览器中,我看到git创建了路径 Plugins / Qt ,并且仅存在来自 Qt-Integration / UEPlugin 的.gitignore。

如果回答“ n”并设置为 git status ,那么您将获得以下信息:

my@DESKTOP-I1D3N52 MINGW64 /c/my/5vid/Test/Cos-Sim (CosmetologyTrainer)
$ git status
On branch CosmetologyTrainer
Your branch is up to date with 'origin/CosmetologyTrainer'.

Changes to be committed:
  (use "git reset HEAD <file>..." to unstage)

        new file:   Plugins/Qt/.gitignore
        new file:   Plugins/Qt/Qt.uplugin
        new file:   Plugins/Qt/README.md
        new file:   Plugins/Qt/Source/Qt/Private/GameWithQtAppInstance.cpp
        new file:   Plugins/Qt/Source/Qt/Private/Qt.cpp
        new file:   Plugins/Qt/Source/Qt/Private/QtPrivatePCH.h
        new file:   Plugins/Qt/Source/Qt/Public/ConvertTemplate.h
        new file:   Plugins/Qt/Source/Qt/Public/GameWithQtAppInstance.h
        new file:   Plugins/Qt/Source/Qt/Public/Qt.h
        new file:   Plugins/Qt/Source/Qt/Public/QtConverters.h
        new file:   Plugins/Qt/Source/Qt/Qt.Build.cs

Changes not staged for commit:
  (use "git add/rm <file>..." to update what will be committed)
  (use "git checkout -- <file>..." to discard changes in working directory)

        deleted:    Plugins/Qt/Qt.uplugin
        deleted:    Plugins/Qt/README.md
        deleted:    Plugins/Qt/Source/Qt/Private/GameWithQtAppInstance.cpp
        deleted:    Plugins/Qt/Source/Qt/Private/Qt.cpp
        deleted:    Plugins/Qt/Source/Qt/Private/QtPrivatePCH.h
        deleted:    Plugins/Qt/Source/Qt/Public/ConvertTemplate.h
        deleted:    Plugins/Qt/Source/Qt/Public/GameWithQtAppInstance.h
        deleted:    Plugins/Qt/Source/Qt/Public/Qt.h
        deleted:    Plugins/Qt/Source/Qt/Public/QtConverters.h
        deleted:    Plugins/Qt/Source/Qt/Qt.Build.cs

我遵循了这个example

为了消除副作用,我在刚克隆的存储库中完成了所有操作。

您能帮忙吗? 我在这个问题上花了太多时间

0 个答案:

没有答案