GitHub link: https://github.com/fsharp/FsAutoComplete License: Apache 2.0
The FsAutoComplete project (FSAC) provides a backend service for rich editing or intellisense features for editors.
It can be hosted using the Language Server Protocol.
Currently it is used by:
It's based on:
FsAutoComplete runs on modern .NET (formerly .NET Core).
FsAutoComplete supports LSP as a communication protocol.
initializetextDocument/didOpentextDocument/didChangetextDocument/didSavetextDocument/hovertextDocument/completion & completionItem/resolvetextDocument/renametextDocument/definitiontextDocument/typeDefinitiontextDocument/implementationtextDocument/codeAction:
open_new keyword for IDisposabletextDocument/codeLens & codeLens/resolve:
textDocument/formatting - powered by fantomastextDocument/referencestextDocument/documentHighlighttextDocument/signatureHelptextDocument/documentSymbolworkspace/didChangeWatchedFilesworkspace/didChangeConfigurationworkspace/symbolCustom endpoints are using (for messages body) PlainNotification type and string format serialized with exactly same serialization format as old JSON protocol
fsharp/signature - accepts TextDocumentPositionParams, returns signature of symbol at given position as a formatted stringfsharp/signatureData - accepts TextDocumentPositionParams, returns signature of symbol at given position as DTOfsharp/lineLens - accepts ProjectParms (Project filed contain F# file path), returns locations where LineLenses should be displayedfsharp/compilerLocation - no input, returns paths to FCS, FSI and MsBuildfsharp/compile - accepts ProjectParms, tries to compile project, returns list of errors and exit status codefsharp/workspacePeek - accepts WorkspacePeekRequest, returns list of possible workspaces (resolved solution files, or list of projects if there are no solution files)fsharp/workspaceLoad - accepts WorkspaceLoadParms, loads given list of projects in the background, partial result notified by fsharp/notifyWorkspace notificationfsharp/project - accepts ProjectParms, loads given projectfsharp/fsdn - accepts ProjectParms (Project filed contain query string), query FSDN and returns list of functionsfsharp/f1Help - accepts TextDocumentPositionParams, returns URL to MSDN documentation for symbol at given positionfsharp/documentation - accepts TextDocumentPositionParams, returns documentation data about symbol at given position, used for InfoPanelfsharp/documentationSymbol - accepts DocumentationForSymbolReuqest, returns documentation data about given symbol from given assembly, used for InfoPanelwindow/showMessagewindow/logMessagetextDocument/publishDiagnosticsfsharp/notifyWorkspace - notification for workspace/solution/project loading eventsfsharp/notifyWorkspacePeek - notification for initial workspace peek--background-service-enabled - passing this flag enables background service feature, increasing FSAC responsiveness by moving some of the operations (especially background type checking) to other process. It results in increased memory usage. Used by default in Ionide.--verbose - passing this flag enables additional logging being printed out in stderrDOTNET_ROOT - setting this environment variable will set the dotnet SDK root, which is used when finding references for FSX scripts.Options that should be send as initializationOptions as part of initialize request.
AutomaticWorkspaceInit - setting it to true will start Workspace Loading without need to run fsharp/workspacePeek and fsharp/workspaceLoad commands. It will always choose top workspace from the found list - all projects in workspace if 0 .sln files are found, .sln file if 1 .sln file was found, .sln file with most projects if multiple .sln files were found. It's designed to be used in clients that doesn't allow to create custom UI for selecting workspaces.FSharp.keywordsAutocomplete - provides keywords in autocomplete list, recommended default value: trueFSharp.ExternalAutocomplete - provides autocomplete for symbols from not opened namespaces/modules, insert open on accept, recommended default value: falseFSharp.Linter - enables FSharpLint integration, provides additional warnings and code action fixes, recommended default value: trueFSharp.UnionCaseStubGeneration - enables code action to generate pattern matching cases, recommended default value: trueFSharp.UnionCaseStubGenerationBody - defines dummy body used by pattern matching generator, recommended default value: "failwith \"Not Implemented\""FSharp.RecordStubGeneration - enables code action to generate record stub, recommended default value: trueFSharp.RecordStubGenerationBody - defines dummy body used by record stub generator, recommended default value: "failwith \"Not Implemented\""FSharp.InterfaceStubGeneration - enables code action to generate interface stub, recommended default value: trueFSharp.InterfaceStubGenerationObjectIdentifier - defines object identifier used by interface stub generator,recommended default value: "this"FSharp.InterfaceStubGenerationMethodBody - defines dummy body used by interface stub generator, recommended default value: "failwith \"Not Implemented\""FSharp.UnusedOpensAnalyzer - enables unused open detections, recommended default value: trueFSharp.UnusedDeclarationsAnalyzer - enables unused symbol detection, recommended default value: trueFSharp.UseSdkScripts - enables the use of .NET (Core) SDKs for script file type-checking and evaluation, otherwise the .NET Framework reference lists will be used. Current default and recommended value: trueFSharp.SimplifyNameAnalyzer - enables simplify name analyzer and remove redundant qualifier quick fix, recommended default value: falseFSharp.ResolveNamespaces - enables resolve namespace quick fix (add open if symbol is from not yet opened module/namespace), recommended default value: trueFSharp.EnableReferenceCodeLens - enables reference count code lenses, recommended default value: true if --background-service-enabled is used by default, false otherwiseFSharp.dotNetRoot - sets the root path for finding dotnet SDK references. Primarily used for FSX Scripts. Default value: operating-system dependent. On windows, C:\Program Files\dotnet; on Unix, /usr/local/share/dotnetFSharp.fsiExtraParameters - an array of additional runtime arguments that are passed to FSI. These are used when typechecking scripts to ensure that typechecking has the same context as your FSI instances. An example would be to set the following parameters to enable Preview features (like opening static classes) for typechecking.