我有一个自托管的gitlab ce服务。
我在网站上看不到我的仓库的主分支。
在发现问题后尝试以下操作:
(master)# git push -u origon/master
error: src refspec refs/heads/master does not match any.
error: failed to push some refs to 'origon/master'
git fetch
也不起作用。
2.在网站上创建一个新的 master 分支。不起作用
所以我去检查gitlab服务器上的仓库。但是没有指向任何提交。
root@Gitlab:/var/opt/gitlab/git-data/repositories/lianjc/Intelligent_Entrance_Guard.git# cat refs/heads/
for_origin_db m2 master
root@Gitlab:/var/opt/gitlab/git-data/repositories/lianjc/Intelligent_Entrance_Guard.git# cat refs/heads/
for_origin_db m2 master
root@Gitlab:/var/opt/gitlab/git-data/repositories/lianjc/Intelligent_Entrance_Guard.git# cat refs/heads/m
m2 master
root@Gitlab:/var/opt/gitlab/git-data/repositories/lianjc/Intelligent_Entrance_Guard.git# cat refs/heads/master
root@Gitlab:/var/opt/gitlab/git-data/repositories/lianjc/Intelligent_Entrance_Guard.git# cat refs/heads/m2
852a5dfd5849ccb81def6f0ef223dbed87ff7f6e
root@Gitlab:/var/opt/gitlab/git-data/repositories/lianjc/Intelligent_Entrance_Guard.git# cat refs/heads/for_origin_db
852a5dfd5849ccb81def6f0ef223dbed87ff7f6e
我可以只编辑文件“ refs / heads / master”,使其指向提交吗? 或者我可以在网站上做任何事情?
对不起,我英语不好。
enter image description here无法发布图片。