致命:参考不是一棵树:发展



我们在GitLab 6.2.1-0和Git 1.8.3上我试图接受从开发分支到生产分支的合并请求,GitLab UI 不允许您接受合并请求。单击"接受合并请求"不会执行任何操作。深入挖掘,它只发生在单个项目中,该项目开始在主机中出现"致命:引用不是树:"错误.log

它一直在工作,直到我们最近重新启动了 GitLab 服务器

February 16, 2016 10:29 -> ERROR -> Command failed --git-dir=/opt/gitlab-6.2.1-0/apps/gitlab/gitlab-satellites/projectname/.git checkout develop    
fatal: reference is not a tree: develop
February 16, 2016 10:29 -> ERROR -> Command failed --git-dir=/opt/gitlab-6.2.1-0/apps/gitlab/gitlab-satellites/projectname/.git push origin prod
error: src refspec prod does not match any.
error: failed to push some refs to '/opt/gitlab-6.2.1-0/apps/gitlab/repositories/projectname.git'

导航到 git 项目目录,显示它当前在_parkingbranch,其中所有其他项目将显示开发分支

cd /opt/gitlab-6.2.1-0/apps/gitlab/gitlab-satellites/projectname
git status
# On branch __parking_branch
nothing to commit, working directory clean

我尝试切换分支进行开发,但没有帮助。

git checkout develop
fatal: reference is not a tree: develop

这是在实际的 git 服务器本身上发生的,而不是在我的本地机器上。任何指示都高度赞赏。

答案很晚,但我也有类似的问题。我试图拉入旧分支,但显示相同的消息,所以我创建了一个本地临时分支,并对原始分支进行了硬重置。然后,我将临时分支重命名为具有其原产地的名称。

在简历中,这些是步骤:

  1. 创建本地分支

    git 结帐 -b 温度

  2. 使用所需的分支进行硬重置

    git reset --硬源/分支名称

  3. 重命名临时分支

    git 分支 -m 分支名称

使用 Xcode 版本 14.3 beta 2 (14E5207e( 重置包缓存为我解决了这个问题。

我怀疑问题是由于尝试在同一项目上使用Xcode发布和测试版而没有正确清除然后手动项目引起的。

最新更新