Lsp-mode: [Documentation] Combine custom language server docs with generated docs

Created on 18 Nov 2020  路  8Comments  路  Source: emacs-lsp/lsp-mode

Currently most language docs are automatically generated. Some, however are custom made and have to be updated manually (see the list below).

Proposal
It would be nice if the documentation supported a custom section, with generated documentation filled in. This would combine the generated documentation with the manually written documentation.

Benefits

  • Automation ensures the functions and variables in the docs are up to date.
  • Human error can be prevented.
  • Documentation will be more complete and won't have missing parts, like the Rust language documenation, which does not document every option.

List of custom language documentation

documentation

Most helpful comment

Yes! it's done here: https://github.com/emacs-lsp/lsp-mode/pull/2346
Today it's a holiday in my country so I got some time to code that :)

All 8 comments

Sounds good. What is your proposal, having placeholder(s) in the custom language documentation and populating them from the automatic one?

@ericdallo , any thoughts?

Yeah, some placeholder would be a solution, but I'm not sure if it's trivial, I think I can take a look at this weekend :)

What is your proposal, having placeholder(s) in the custom language documentation and populating them from the automatic one?

Yes, this is what I had in mind. Right now there are two templates. I propose combining these two into one, resulting in a template like this:

{{full-name}}
==========

## Server

{{documenation}} <!-- This is custom documenation, grabbed from a different markdown file. -->

For more information about the LSP server, check the [{{server-name}}]({{server-url}}).

## Installation

{{installation}}{{installation-url}}

### Debugger: {{debugger}}

## Available configurations

<generated documentation here>   

This template is then used by the generation script as usual, and the custom documentation is placed on the spot it is used at!

WDYT?

Looks good to me. I would put the debugger and configuration installation section above the documentation section.

Looks good to me. I would put the debugger and configuration installation section above the documentation section.

Agreed.

@jarivm are you going to work on that? (I am asking in order to avoid collisions)

@yyoncho I thought @ericdallo would take a look at it this weekend, so I am not going to work on it. @ericdallo can you confirm this? Otherwise I will work on it next week :)

Yes! it's done here: https://github.com/emacs-lsp/lsp-mode/pull/2346
Today it's a holiday in my country so I got some time to code that :)

Was this page helpful?
0 / 5 - 0 ratings

Related issues

raxod502 picture raxod502  路  5Comments

dchneric picture dchneric  路  3Comments

axelson picture axelson  路  4Comments

kmdouglass picture kmdouglass  路  3Comments

xendk picture xendk  路  3Comments