Sourcegraph for Firefox EN
Sourcegraph · Firefox
Adds code intelligence to GitHub, GitLab, Bitbucket Server, and Phabricator: hovers, definitions, references. Supports 20+ languages.
<all_urls>),意味着它可以读取你在任意站点的页面内容,包括已登录的页面。这是许多扩展正常工作的必要条件,但也值得你确认来源可信。
截图
简介
The open-source Sourcegraph extension adds code navigation and code intelligence to GitHub, GitHub Enterprise, GitLab, Bitbucket Server, and Phabricator.
• Code intelligence on your code host:
* Hover tooltips with documentation and type information
* Go to definition
* Find references
• Integrations with third-party services like Codecov coverage overlays, open-in-editor buttons and many more with Sourcegraph extensions
• Browser shortcut (src + Space) that performs the search on your Sourcegraph instance
It works for 20+ languages on public and private code on popular code hosts (see below).
Make it work on your code host:
• GitHub - No action required. Your extension works here by default.
• GitHub Enterprise, GitLab, Bitbucket Server and Phabricator - grant additional permissions in the extension menu
Browser extension docs: https://docs.sourcegraph.com/integration/browser_extension
Make it work for private code:
To use the browser extension with your private repositories, you need to set up a private Sourcegraph instance and connect it to the extension.
Installation docs: https://docs.sourcegraph.com/admin/install
Where to start?
After adding the extension you install it, try it out on any of these public repositories:
• Go: https://github.com/gorilla/mux/blob/9e1f59/mux.go or https://github.com/dgrijalva/jwt-go/pull/152/files#diff-f615844d3497ff38db57e459d6ef657bL48
• Java: https://github.com/google/guava/blob/581ba1/guava/src/com/google/common/collect/ImmutableList.java
• TypeScript: https://github.com/angular/angular/blob/a2878b/packages/benchpress/src/reporter/console_reporter.ts or https://github.com/sindresorhus/got/pull/917/files#diff-02301bc46e8b878f10e9a8339efb7de7R176
• C#: https://github.com/paiden/Nett/pull/76/files#diff-e969e1315b2cb01bab80b2860be0d87eR52
• Python: https://github.com/ageitgey/face_recognition/blob/b8fed6/examples/facerec_on_raspberry_pi.py
This extension is open source: https://github.com/sourcegraph/sourcegraph/tree/master/browser
Sourcegraph for Firefox 是做什么的
Sourcegraph for Firefox 是一款面向 Firefox 的开发者工具类扩展,主要用来调试页面、查看样式与请求、测试接口、辅助前端开发。官方对它的介绍是:Adds code intelligence to GitHub, GitLab, Bitbucket Server, and Phabricator: hovers, definitions, references. Supports 20+ languages.在Firefox 附加组件商店(AMO)上,它当前版本 23.4.14.1343,评分 5(8 人评价),约 368 名用户。
适合什么人用
从功能定位看,Sourcegraph for Firefox 更适合前端工程师、测试与需要经常查看页面结构的用户。如果你平时只是偶尔遇到相关需求,用浏览器自带功能也能凑合;但如果这件事每天都发生,装一个专门处理它的扩展通常比手动操作省事得多。需要注意的是它作用于所有网站,装上后建议先观察一两天,确认不影响常用站点的正常使用。
怎么安装 Sourcegraph for Firefox
- 打开Firefox 附加组件商店(AMO)上的官方页面;
- 点「添加到浏览器」并确认权限提示;
- 装好后在扩展列表里固定图标,方便随时开关。
本站只做索引与介绍,安装包来自官方商店。如果商店页面提示当前地区不可用,说明该扩展未在你所在区域上架。
常见问题
Sourcegraph for Firefox 是免费的吗?
Sourcegraph for Firefox 在Firefox 附加组件商店(AMO)免费提供下载。它是浏览器扩展,装上就能直接用,不需要注册账号。
Sourcegraph for Firefox 安全吗?
它只申请了 0 项权限,范围比较克制,没有申请「读取所有网站数据」这种大权限。
Sourcegraph for Firefox 支持哪些浏览器?
当前收录的版本来自Firefox 附加组件商店(AMO),适用于 Firefox。同一个扩展在其他商店可能有对应版本,但功能与版本号不一定相同。
怎么卸载 Sourcegraph for Firefox?
在扩展管理页找到 Sourcegraph for Firefox,点移除即可。它在本地保存的设置会一起清掉,不会残留数据。
权限清单 来自 manifest.json 原文
站点访问 1
<all_urls>
站点访问(可选) 2
http://*/*https://*/*
接口权限 3
activeTabcontextMenusstorage
接口权限(可选) 1
tabs


