3

当我尝试“git push origin master”时,我收到错误“被fallthru拒绝”

我花了过去三个小时在谷歌上搜索。我不知道如何解决它。

gitolite.log

2012-10-15.16:43:47 16930   ssh ARGV=david_neudorfer_lbox_com_1350337154    SOC=git-receive-pack 'Treasure-Hunt.git'    FROM=10.0.4.185
2012-10-15.16:43:47 16930       repo 'Treasure-Hunt' missing
2012-10-15.16:43:47 16930       access(Treasure-Hunt, david_neudorfer_lbox_com_1350337154, W, 'any'),-> W any Treasure-Hunt david_neudorfer_lbox_com_1350337154 DENIED by fallthru
2012-10-15.16:43:47 16930       trigger,Writable,access_1,ACCESS_1,Treasure-Hunt,david_neudorfer_lbox_com_1350337154,W,any,W any Treasure-Hunt david_neudorfer_lbox_com_1350337154 DENIED by fallthru
2012-10-15.16:43:47 16930   die W any Treasure-Hunt david_neudorfer_lbox_com_1350337154 DENIED by fallthru<<newline>>(or you mis-spelled the reponame)

gitolite.conf

repo    test_project
  RW+                            = david_neudorfer_lbox_com_1350344583
repo    projectsmadesimple-web
  RW+                            = david_neudorfer_lbox_com_1350344583
repo    treasure-hunt
  RW+                            = david_neudorfer_lbox_com_1350344583

我注意到名字后面的数字不同。希望与它有关,我尝试过:

repo    test_project
  RW+                            = david_neudorfer_lbox_com_1350344583
  RW+                            = david_neudorfer_lbox_com_1350337154

没用。任何建议都会很棒。

4

2 回答 2

3

作为cjc343 评论,最后一个错误行告诉我们:

2012-10-15.16:43:47 16930   die W any Treasure-Hunt 
                            DENIED by fallthru
                            (or you mis-spelled the reponame)

该错误消息来自src/gitolite-shell 的 main() 函数,在调用src/lib/Gitolite/Conf/Load.pm repo_missing() 函数之后

sub repo_missing {
    my $repo = shift;
    sanity($repo);

    return not -d "$rc{GL_REPO_BASE}/$repo.git";
}

它查找一个目录,在 Unix 系统上,该目录区分大小写。

然后您需要解决 id 问题:您应该始终使用相同的名称进行身份验证。

于 2012-10-16T05:26:58.593 回答
1

已解决:
在我的情况下,我将 repo 从我的帐户移动到一个组,因此 repo 的路径在远程更改,但在我的本地 repo 中没有。

所以我更改了本地仓库(配置文件)中的路径:

[remote "origin"]
url = git@git.me:mygroup/repo.git              // previously git@git.me:myname/repo.git
fetch = +refs/heads/*:refs/remotes/origin/*
于 2013-12-23T10:14:37.573 回答