Getting started
Installing srclib
To install the src program, download one of the prebuilt binaries or build it from source (see next section).
src binary downloads:
After downloading the file, unzip it and place the src
program in your
$PATH
. Run src --help
to verify that it's installed.
To install the standard set of language analysis toolchains (Go, Ruby, JavaScript, and Python), run:
src toolchain install-std
By default this installs the toolchains for Ruby, Go, JavaScript, and Python. To skip installing toolchains you don't care about, use --skip
, as in src toolchain install-std --skip javascript --skip go
.
If this command fails, please file an issue.
Now, src toolchain list
should show the toolchains you just installed.
Building from source
First, install Go (version 1.3 or newer).
Then download and install src
:
go get -u -v sourcegraph.com/sourcegraph/srclib/cmd/src
Next, you must install the language toolchains: src toolchain install-std
. By default this installs the toolchains for Ruby, Go, JavaScript, and Python. To skip installing toolchains you don't care about, use --skip
, as in src toolchain install-std --skip javascript --skip go
.
Now, src toolchain list
should show the toolchains you just installed.
Next steps
Download an editor plugin
If you are interested in using the editor plugins that we have available, check out the Editor Plugins section of the documentation. Currently, Emacs Sublime Text and Atom are supported, and support for more editors is coming soon.
Build on srclib
If you want to help build/improve editor plugins, or simply hack on srclib, read through the docs on Building on srclib.
Contribute to srclib
Finally, if you want to help build out the language analysis infrastructure, make sure you're familiar with the API. Then, read closely over the Creating a Toolchain section.