p4analyzer icon indicating copy to clipboard operation
p4analyzer copied to clipboard

Native File System and File Watcher

Open timjroberts opened this issue 1 year ago • 1 comments

The core LSP types define an EnumerableFileSystem trait. We have an implementation of this trait that sends requests to the LSP client to enumerate the files of workspaces (i.e., as part of indexing), and to retrieve file contents. This implementation uses new LSP request types (extensions), and these are supported directly in Visual Studio Code through our own LSP client implementation.

To support LSP environments outside of Visual Studio Code, we will need another implementation of the EnumerableFileSystem trait that enumerates and reads the file system directly. This implementation should also be extended to optionally watch for file changes, and report them as appropriate LSP notifications.

timjroberts avatar May 19 '23 14:05 timjroberts

Native filesystem for non-wasm build of P4Analyzer has been merged. Unit tests are passing & system is working on Unix, but it's not working on Windows.

Native file watcher wasn't implemented, but a draft was started. That was later removed from the merge and can be seen in this commit

AndrewF001 avatar Jun 08 '23 12:06 AndrewF001