Emacs Plugin

Disclaimer

Editor plugins are temporarily incompatible with srclib master. Please download an older version of srclib to use editor plugins.

Features

  • Documentation lookups
  • Type information
  • Find usages (across all open-source projects globally)


Installation Instructions

First, make sure you've installed srclib, along with the toolchains for the programming languages you're using. Once srclib is installed, you can install the emacs plugin by navigating to your .emacs.d directory and cloning the repository.

cd ~/.emacs.d
git clone https://github.com/sourcegraph/emacs-sourcegraph-mode.git

To install the plugin, append the following code to ~/.emacs.d/init.el.

(add-to-list 'load-path "~/.emacs.d/emacs-sourcegraph-mode")
(require 'sourcegraph)

Sourcegraph-mode can be enabled in a buffer with M-x, then typing sourcegraph-mode.

Now, in any file (with sourcegraph-mode enabled), run sourcegraph-describe (or C-M-.) to see docs, type info, and examples.

Note that the default CLI emacs app in OS X doesn't enable json-mode. Do not use it. If you do, there will be always one error message to load the .emacs file.


Contribute on GitHub