You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
/** The path at which SourceKit-LSP can store its index database, aggregating data from `indexStorePath`.
18
+
* This should point to a directory that can be exclusively managed by SourceKit-LSP. Its exact location can be arbitrary. */
19
+
indexDatabasePath?:string;
20
+
17
21
/** The directory to which the index store is written during compilation, ie. the path passed to `-index-store-path`
18
22
* for `swiftc` or `clang` invocations **/
19
23
indexStorePath?:string;
20
24
21
-
/** The path at which SourceKit-LSP can store its index database, aggregating data from `indexStorePath`.
22
-
* This should point to a directory that can be exclusively managed by SourceKit-LSP. Its exact location can be arbitrary. */
23
-
indexDatabasePath?:string;
25
+
/** Whether the server implements the `buildTarget/outputPaths` request. */
26
+
outputPathsProvider?:bool;
24
27
25
28
/** Whether the build server supports the `buildTarget/prepare` request */
26
29
prepareProvider?:bool;
@@ -43,6 +46,37 @@ If `data` contains a string value for the `workDoneProgressTitle` key, then the
43
46
44
47
`changes` can be `null` to indicate that all targets have changed.
45
48
49
+
## `buildTarget/outputPaths`
50
+
51
+
For all the source files in this target, the output paths that are used during indexing, ie. the `-index-unit-output-path` for the file, if it is specified in the compiler arguments or the file that is passed as `-o`, if `-index-unit-output-path` is not specified.
52
+
53
+
This allows SourceKit-LSP to remove index entries for source files that are removed from a target but remain present on disk.
54
+
55
+
The server communicates during the initialize handshake whether this method is supported or not by setting `outputPathsProvider: true` in `SourceKitInitializeBuildResponseData`.
56
+
57
+
- method: `buildTarget/outputPaths`
58
+
- params: `OutputPathsParams`
59
+
- result: `OutputPathsResult`
60
+
61
+
```ts
62
+
exportinterfaceBuildTargetOutputPathsParams {
63
+
/** A list of build targets to get the output paths for. */
64
+
targets:BuildTargetIdentifier[];
65
+
}
66
+
67
+
exportinterfaceBuildTargetOutputPathsItem {
68
+
/** The target these output file paths are for. */
69
+
target:BuildTargetIdentifier;
70
+
71
+
/** The output paths for all source files in this target. */
72
+
outputPaths:string[];
73
+
}
74
+
75
+
exportinterfaceBuildTargetOutputPathsResult {
76
+
items:BuildTargetOutputPathsItem[];
77
+
}
78
+
```
79
+
46
80
## `buildTarget/prepare`
47
81
48
82
The prepare build target request is sent from the client to the server to prepare the given list of build targets for editor functionality.
@@ -53,6 +87,7 @@ The server communicates during the initialize handshake whether this method is s
0 commit comments