github常用搜索

不得不说 GitHub 简直就是程序猿的福地,聚集了众多大神在上面分享,在这里可以发现无限的优良资源,不管是初学者还是正在进阶中的青铜王者,都可以在上面找到适合自己的好东西,用好 GitHub 可以让能力提升不止一点点。

那么,如何在这么庞大的资源平台下找到自己想要的内容呢?我搜集了一些实用的技巧,可以快速的定位到你想看到的内容,用好这些技巧,你就可以在这上面如鱼得水了。

搜索仓库

  • in:name jquery in:name 匹配其名称中含有 "jquery" 的仓库。

  • in:description jquery in:name,description 匹配其名称或说明中含有 "jquery" 的仓库。

  • in:readme jquery in:readme 匹配其自述文件中提及 "jquery" 的仓库。

  • size:n size:1000 匹配恰好为 1 MB 的仓库。

  • ...

  • https://help.github.com/cn/github/searching-for-information-on-github/searching-for-repositories

搜索代码

  • in:file octocat in:file 匹配文件内容中出现 "octocat" 的代码。

  • in:path octocat in:path 匹配文件路径中出现 "octocat" 的代码。

  • 在用户或组织的仓库内搜索

    • user:Daotin

    • org: orgName

  • 按文件名搜索  filename:FILENAME

  • 按文件后缀搜索  extension:md

  • ...

  • https://help.github.com/cn/github/searching-for-information-on-github/searching-code

搜索用户和组织

  • Daotin type:user

  • xxx type:org

  • user:name user:octocat 匹配用户名为 "octocat" 的用户。

  • org:name org:electron type:users 匹配 Electron 组织的帐户名。

  • in:login kenya in:login 匹配其用户名中含 "kenya" 字样的用户。

  • in:email data in:email 匹配其电子邮件中含有 "data" 字样的用户。

  • ...

  • https://help.github.com/cn/github/searching-for-information-on-github/searching-users

原文地址:https://www.cnblogs.com/lvonve/p/14180279.html