首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >无法将HEAD解析为有效的ref

无法将HEAD解析为有效的ref
EN

Stack Overflow用户
提问于 2012-09-25 12:48:04
回答 1查看 8.8K关注 0票数 4

我目前已经在我的私人服务器上切换到了gitolite + gitlist。在gitlist中,我可以看到testrepo和我自己的,gitlist告诉我

代码语言:javascript
复制
Oops! fatal: Failed to resolve HEAD as a valid ref.

配置看起来有效...

代码语言:javascript
复制
[git]
client = '/usr/bin/git' ; Your git executable path
repositories = '/var/www/gitolite/repositories/' ; Path to your repositories

; You can hide repositories from GitList, just copy this for each repository you want to hide
; hidden[] = '/var/www/projects/BetaTest'
hidden[] = /var/www/gitolite/repositories/gitolite-admin.git

[app]
debug = false

; If you need to specify custom filetypes for certain extensions, do this here
[filetypes]
; extension = type
; dist = xml

..。还有存储库

代码语言:javascript
复制
drwxr-xr-x   7 git git 4096 Sep 23 11:53 .
drwxr-xr-x   5 git git 4096 Sep 23 00:19 ..
-rwxr-xr-x   1 git git   23 Sep 23 00:19 HEAD
drwxr-xr-x   2 git git 4096 Sep 23 00:19 branches
-rwxr-xr-x   1 git git   66 Sep 23 00:19 config
-rwxr-xr-x   1 git git  386 Sep 24 17:27 gl-conf
drwxr-xr-x   2 git git 4096 Sep 23 00:19 hooks
drwxr-xr-x   2 git git 4096 Sep 23 00:19 info
drwxr-xr-x 109 git git 4096 Sep 25 00:24 objects
drwxr-xr-x   4 git git 4096 Sep 23 00:19 refs

还有头部

代码语言:javascript
复制
cat HEAD
ref: refs/heads/master

有什么想法吗?

EN

回答 1

Stack Overflow用户

发布于 2012-09-28 13:56:56

检查你的标签和分支。

如果您有一个名为master的标记,那么带有-b master选项的git代码库的git clone也可以使用!(-b接受分支名称或标记)

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/12576337

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档