2015-10-07 92 views
0

假设我想在Linux Kernel中找到某个贡献者的提交。 https://github.com/torvalds/linux/commits/master在GitHub上查找作者没有GitHub帐户的提交

例如,有a recent commit安娜·舒马克创作的(我把最近提交的未通过GitHub的帐户撰写当前历史)。

关于该主题的其他一些SO问题建议使用https://github.com/torvalds/linux/commits/master?author=AUTHOR来查找同一作者的更多提交。

但是:

这是Github的一个缺失功能​​吗?我做错了吗?

P.S.我知道如何使用git命令行工具来完成此操作。我特意寻找与Github做到这一点的方法,因为我希望能够生成一个链接到搜索,以便其他人可以查看网络上的结果。

+0

老板,请接受答案,如果答案可以帮助你! –

回答

5

您可以在author参数中传递用户名或电子邮件地址。如您注意到的,使用?author=torvalds可以提供提交。

由于Anna没有GitHub帐户,您可以使用她的电子邮件。但如何找到知道提交的电子邮件?

拥有commit url(看起来像这样:https://github.com/torvalds/linux/commit/39d0d3bdf7bab3021a31e501172ac0f18947f9b3),最后附加.patch片段。你应该得到类似this

https://github.com/torvalds/linux/commit/39d0d3bdf7bab3021a31e501172ac0f18947f9b3.patch

的回应是这样的:

From 39d0d3bdf7bab3021a31e501172ac0f18947f9b3 Mon Sep 17 00:00:00 2001 
From: Anna Schumaker <[email protected]> 
Date: Mon, 5 Oct 2015 16:43:26 -0400 
Subject: [PATCH] NFS: Fix a tracepoint NULL-pointer dereference 

Running xfstest generic/013 with the tracepoint nfs:nfs4_open_file 
enabled produces a NULL-pointer dereference when calculating fileid and 
filehandle of the opened file. Fix this by checking if state is NULL 
before trying to use the inode pointer. 

Reported-by: Olga Kornievskaia <[email protected].edu> 
Signed-off-by: Anna Schumaker <[email protected]> 
Signed-off-by: Trond Myklebust <[email protected]> 
--- 
fs/nfs/nfs4trace.h | 2 +- 
1 file changed, 1 insertion(+), 1 deletion(-) 

diff --git a/fs/nfs/nfs4trace.h b/fs/nfs/nfs4trace.h 
index 28df12e..671cf68 100644 
--- a/fs/nfs/nfs4trace.h 
+++ b/fs/nfs/nfs4trace.h 
@@ -409,7 +409,7 @@ DECLARE_EVENT_CLASS(nfs4_open_event, 
      __entry->flags = flags; 
      __entry->fmode = (__force unsigned int)ctx->mode; 
      __entry->dev = ctx->dentry->d_sb->s_dev; 
-   if (!IS_ERR(state)) 
+   if (!IS_ERR_OR_NULL(state)) 
       inode = state->inode; 
      if (inode != NULL) { 
       __entry->fileid = NFS_FILEID(inode); 

你在你的作者姓名和电子邮件地址的第二行看到的。现在,知道电子邮件地址,你可以fetch person's commits in that repository

https://github.com/torvalds/linux/[email protected] 
0

好吧,一次又一次,解决问题的最好方法是公开宣布我不知道如何解决它......立即发布问题后,我意识到我没有试过只搜索电子邮件:

https://github.com/torvalds/linux/commits/[email protected]

给出了预期的效果。

+0

我加了一个更详细的答案。也许它会对后代有用。 :) –

+0

@jkff,老板,请接受答案,如果答案可以帮助你!因为对方已经努力提供详细的答案,而你的只是一个可能会及时腐烂的链接。 –

+0

完成,谢谢提醒! – jkff