Commit Graph

13 Commits

Author SHA1 Message Date
Richard Howell
f2b5f2c167 add settings request and tests 2019-09-10 10:40:14 -07:00
David Goldman
e5caf44fda Add a BuildSystemDelegate which supports notifications for build settings changes
Introduce a `BuildSystemDelegate` to handle notifications from the build system

* `SourceKitServer` is the main delegate to process these notifications
* Currently limited to changes in `FileBuildSettings`
* Delegate informs the `BuildSystem` of files to watch via `registerChangeWatching(for: URL)` and `unregisterChangeWatching(for: URL)`
* In the future we could have more integration for handling changes in dependencies

Handling changes in `FileBuildSettings`

* `SourceKitServer` sends notifications to the internal LSPs informing them of any opened documents that have changes in their compiler flags
    * For clangd, we send a notification to update the compilation database
    * For SourceKit/sourcekitd we must close and reopen the file to force a new AST with the new compiler flags
2019-09-06 17:44:36 -04:00
Ben Langmuir
6bb0924de4 Update one more Basic -> TSCBasic from recent commit 2019-09-03 08:38:38 -07:00
Richard Howell
83d0e75fec nicer case matching for response data 2019-08-29 16:12:09 -07:00
Richard Howell
8e8bf8abf2 don't block shutting down build server 2019-08-29 16:05:20 -07:00
Richard Howell
301fa20327 add log message for shutdown errors 2019-08-29 10:20:27 -07:00
Richard Howell
cbd33eed6a add support for index store path via metadata 2019-08-29 10:20:27 -07:00
Richard Howell
7b842235be add build server lifecycle notifications 2019-08-29 10:04:18 -07:00
Richard Howell
58a42b08b3 use Language instead of String 2019-08-28 19:43:10 -07:00
Richard Howell
bfb0eb7cf9 don't forget to actually initialize the server 2019-08-28 15:43:49 -07:00
Richard Howell
fd6cdfb603 use Codable, start server as part of init, no log on missing config 2019-08-28 15:35:57 -07:00
Richard Howell
89f62f8229 add copyright headers 2019-08-28 15:15:59 -07:00
Richard Howell
366f7d930d Add initial BuildServerBuildSystem based on BSP 2019-08-27 15:47:40 -07:00