Skip to content

Commit 9ee1e89

Browse files
committed
Add explanation for cross-repository navigation
1 parent abf6fcd commit 9ee1e89

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed

docs/getting-started.md

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -152,6 +152,8 @@ libraryDependencies += "com.sourcegraph" %% "scip-java" % "@STABLE_VERSION@"
152152
> [Supported build tools](#supported-build-tools) for more details about other
153153
> build tools.
154154
155+
> For cross-repository navigation, additional dependency metadata is required (for Gradle, enable `maven-publish`); see [Cross-Repository Navigation (Optional)](#cross-repository-navigation-optional).
156+
155157
Run the `scip-java index` command to generate a SCIP index for your codebase.
156158
This command should automatically infer the structure of your codebase and
157159
configure your build tool to generate SCIP.
@@ -180,6 +182,22 @@ scip-java index -- --batch-mode -DskipTests package
180182

181183
The `index.scip` file contains the SCIP index and is ready to be used.
182184

185+
### Cross-Repository Navigation (Optional)
186+
187+
By default, `scip-java index` enables navigation within the local repository.
188+
To enable cross-repository navigation, `scip-java` needs dependency metadata
189+
from your build.
190+
191+
For Gradle builds, this requires enabling `maven-publish` and defining a Maven
192+
publication (for example, from `components["java"]`) in `build.gradle` or
193+
`build.gradle.kts`.
194+
195+
If this is not configured, indexing may still succeed, but cross-repository
196+
definitions/references may not resolve.
197+
198+
See [Manual configuration: Step 4 (optional): Enable cross-repository navigation](manual-configuration.md#step-4-optional-enable-cross-repository-navigation)
199+
for detailed setup options.
200+
183201
> Running `scip-java index` may perform side-effects on your build like cleaning
184202
> the compile cache before indexing. This is done to make sure that all source
185203
> files in the codebase get indexed.

0 commit comments

Comments
 (0)