Skip to content
Java LSIF indexer
Java Shell
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
examples/small
gradle/wrapper
src/main/java
.gitignore
README.md
build.gradle
dev
gradlew
gradlew.bat
pom.xml
settings.gradle

README.md

Java LSIF indexer

Prerequisites

  • Java 1.8 or higher installed on your machine
  • Maven

Installation

git clone https://github.com/sourcegraph/lsif-java
cd lsif-java
./gradlew installDist

Usage

Configuring your project

Make sure there is a pom.xml in the project root. For Gradle projects, you can create a pom.xml by first adding a createPom task then running gradle createPom. Here's an example task:

task createPom  {
    pom { }.writeTo("pom.xml")
}

Indexing your repository (generate LSIF data)

Then run the Java LSIF indexer:

<absolute path to lsif-java>/build/install/lsifjava/bin/lsifjava \
  -noContents \
  -projectRoot <project directory> \
  -out dump.lsif

Comparison to Microsoft/lsif-java

  • sourcegraph/lsif-java is ~10x faster
  • sourcegraph/lsif-java supports cross-file hovers/definitions/references (Microsoft/lsif-java does not)
  • sourcegraph/lsif-java uses Spoon, which is built on eclipse.jdt.core
  • Microsoft/lsif-java uses eclipse.jdt.ls, which is also built on eclipse.jdt.core

See https://github.com/microsoft/lsif-java/issues/61 for the status of collaboration efforts.

Development

./dev
You can’t perform that action at this time.