Gitk没有显示主人的头像? [英] Gitk does not show HEAD of master?

查看:246
本文介绍了Gitk没有显示主人的头像?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

这是在Ubuntu 14.04上, git 版本1.9.1(与 gitk 相同)。我这样做:

  $ cd / tmp 
$ git clone https://github.com/underdoeg /ofxLibRocket.git ofxLibRocket-git
克隆到'ofxLibRocket-git'...
remote:计数对象:1013,完成。
remote:合计1013(delta 0),重用0(delta 0),包重用1013
接收对象:100%(1013/1013),16.85 MiB | 326.00 KiB / s,完成。
解决三角洲问题:完成100%(631/631)。
检查连通性...完成。
$ cd ofxLibRocket-git
$ git status
在分支大师
你的分支是最新的'origin / master'。

没有提交,工作目录清理
$ git log -1 --decorate
commit 14360ed8fd3428aa0a2e052f6363e5daa0bf0d75(HEAD,origin / master,origin / HEAD,master)
合并:06dd209 801877c
作者:Philip Whitfield< philip@undef.ch>
Date:Fri Feb 22 03:16:37 2013 -0800

合并neilmendoza / master的请求#6

修复OSX库和示例
$ gitk --all。

到目前为止 - ,如果我运行 gitk --all。,那么当前HEAD的提交在 gitk 中指明 not 显示?这是我得到的:





那么这是 gitk 中的一个bug,还是 gitk 需要一些特殊的设置(比如说命令行开关)来显示这个存储库的状态? >


  1. gitk --all 没有路径规范给出了预期的结果,正如 gitg
  2. 完全忽略 - all 切换并显示修改给定文件并且不收集任何引用的第一个提交。所以我再也不会把它称为一个错误,只是一个呃,它的实施方式。另外我应该提到,在 gitk 命令行中指定一个文件对我来说是一件不寻常的事情。


This is on Ubuntu 14.04, git version 1.9.1 (same for gitk). I'm doing this:

$ cd /tmp
$ git clone https://github.com/underdoeg/ofxLibRocket.git ofxLibRocket-git
Cloning into 'ofxLibRocket-git'...
remote: Counting objects: 1013, done.
remote: Total 1013 (delta 0), reused 0 (delta 0), pack-reused 1013
Receiving objects: 100% (1013/1013), 16.85 MiB | 326.00 KiB/s, done.
Resolving deltas: 100% (631/631), done.
Checking connectivity... done.
$ cd ofxLibRocket-git
$ git status
On branch master
Your branch is up-to-date with 'origin/master'.

nothing to commit, working directory clean
$ git log -1 --decorate
commit 14360ed8fd3428aa0a2e052f6363e5daa0bf0d75 (HEAD, origin/master, origin/HEAD, master)
Merge: 06dd209 801877c
Author: Philip Whitfield <philip@undef.ch>
Date:   Fri Feb 22 03:16:37 2013 -0800

    Merge pull request #6 from neilmendoza/master

    Fixed OSX libs and example
$ gitk --all .

So far so good - but, if I run gitk --all . in this directory, then the commit of current HEAD is not indicated in the gitk display? This is what I get:

This is the weird thing: the only commit containing the word OSX shown in gitk, which I've selected manually:

  • has the hash 801877c48390324dc7d600936306cd7c00486dcc, unlike what git log shows for current head, 14360ed8fd3428aa0a2e052f6363e5daa0bf0d75
  • The 14360ed8 is the "merge pull request" by one committer, the 801877c the pull request by another committer, for the same patch/commit, "Fixed OSX libs and example"
  • The 14360ed8 is not listed in any commit of gitk
  • There is no yellow dot to indicate HEAD, nor a "master" branch label, anywhere in gitk (and certainly not next to 801877c).

So, why doesn't gitk in this case show the HEAD and the 14360ed8 commit? I have tried doing:

git checkout master
git reset --hard HEAD

... but it seems to make no difference in terms of display in gitk... How can I get the proper display of HEAD and the master branch in this case?


EDIT: So, I installed gitg (Version 0.2.7), and it seems to make more sense visualisation-wise:

So is this a bug in gitk, or does gitk need some special setup (say, command line switches) to show this state of the repository?

解决方案

  1. gitk --all without path specification gives the expected result, exactly as gitg
  2. It seems that gitk <some path> completely ignores --all switch and displays the first commit which modifies a given file and doesn't collect any references. So again I wouldn't call it a bug, just a, hmm, way it's implemented. Also I should mention that specifying a file in the command line for gitk is a unusual thing for me.

这篇关于Gitk没有显示主人的头像?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆