From 5af6e558147a90e3b89fc19ae8ea1dbb63effbfb Mon Sep 17 00:00:00 2001 From: TJ DeVries Date: Wed, 23 Nov 2016 22:32:45 -0500 Subject: [PATCH] WIP: adding information about default configuration --- .gitignore | 1 + autoload/langserver/mappings.vim | 2 +- doc/langserver.txt | 9 +++ .../freebroccolo_ocaml-language-server.json | 63 +++++++++++++++++++ 4 files changed, 74 insertions(+), 1 deletion(-) create mode 100644 preconfigured/freebroccolo_ocaml-language-server.json diff --git a/.gitignore b/.gitignore index 8d87b1d..3bc9745 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ node_modules/* +*tags* diff --git a/autoload/langserver/mappings.vim b/autoload/langserver/mappings.vim index e27166b..77b36d4 100644 --- a/autoload/langserver/mappings.vim +++ b/autoload/langserver/mappings.vim @@ -8,6 +8,6 @@ function! langserver#mappings#default(opts) abort nnoremap (langserver_hover_request) :call langserver#hover#request() " Reference mappings - nnoremap (langserver_textdocument_references) :call langserver#references#request() + nnoremap (langserver_textdocument_references_request) :call langserver#references#request() endfunction diff --git a/doc/langserver.txt b/doc/langserver.txt index 007d2b6..9695c11 100644 --- a/doc/langserver.txt +++ b/doc/langserver.txt @@ -34,6 +34,15 @@ Define a dictionary like this in your vimrc. > \ }, \ } + +===== IN PROGRESS ===== ~ + +In general, it is recommended that you name the server with the convention of +{repository_host}/{repository_name}. There will be configuration defaults set +for known language servers to try and ease the startup difficulty for users. + +==========~ + TODO: Mappings Plug Mappings: diff --git a/preconfigured/freebroccolo_ocaml-language-server.json b/preconfigured/freebroccolo_ocaml-language-server.json new file mode 100644 index 0000000..f503bc5 --- /dev/null +++ b/preconfigured/freebroccolo_ocaml-language-server.json @@ -0,0 +1,63 @@ +{ + "properties": { + "reason.codelens.unicode": { + "type": "boolean", + "default": true, + "description": "Enable the use of unicode symbols in codelens." + }, + "reason.server.languages": { + "type": "array", + "items": { + "enum": [ + "reason" + ] + }, + "default": [ + "reason" + ], + "maxItems": 1, + "uniqueItems": true, + "description": "The list of languages enable support for in the language server." + }, + "reason.debounce.linter": { + "type": "integer", + "default": 500, + "description": "How long to idle (in milliseconds) after keypresses before refreshing linter diagnostics. Smaller values refresh diagnostics more quickly." + }, + "reason.path.ocamlfind": { + "type": "string", + "default": "ocamlfind", + "description": "The path to the `ocamlfind` binary." + }, + "reason.path.ocamlmerlin": { + "type": "string", + "default": "ocamlmerlin", + "description": "The path to the `ocamlmerlin` binary." + }, + "reason.path.opam": { + "type": "string", + "default": "opam", + "description": "The path to the `opam` binary." + }, + "reason.path.rebuild": { + "type": "string", + "default": "rebuild", + "description": "The path to the `rebuild` binary." + }, + "reason.path.refmt": { + "type": "string", + "default": "refmt", + "description": "The path to the `refmt` binary." + }, + "reason.path.refmterr": { + "type": "string", + "default": "refmterr", + "description": "The path to the `refmterr` binary." + }, + "reason.path.rtop": { + "type": "string", + "default": "rtop", + "description": "The path to the `rtop` binary." + } + } +}