Skip to content

Instantly share code, notes, and snippets.

@pynappo
Last active April 26, 2024 05:55
Show Gist options
  • Star 3 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save pynappo/c3bca45f6a227a4aa0cba3daa48f776a to your computer and use it in GitHub Desktop.
Save pynappo/c3bca45f6a227a4aa0cba3daa48f776a to your computer and use it in GitHub Desktop.
A chart describing neovim lsp vs coc
%%{init: {"flowchart": {"htmlLabels": false}} }%%
flowchart LR
  subgraph LSP
    subgraph lsp.install [Install language servers]
      subgraph mason-pkg [Local to neovim]
        mason.nvim
      end
      system-pkg["System
      package managers"]
      subgraph coc-install ["coc.nvim (Local to (neo)vim)"]
        :CocInstall
      end
    end
    mason.nvim ==usually paired with==> mason-lspconfig
    mason.nvim -.-> config.manual
    coc-install -.-> coc-config
    system-pkg --> nvim-lspconfig & config.manual
    subgraph lsp.config [LSP configuration]
      subgraph config.easy [Convienient setup]
        subgraph Adapter + autoconfigure
          mason-lspconfig
        end
        mason-lspconfig --> nvim-lspconfig
        nvim-lspconfig
      end
      subgraph config.manual [Manual setup]
        vim.lsp.start["vim.lsp.start()
        + ftplugins"]
      end
      subgraph coc-config [coc.nvim + json]
        :CocConfig
      end
    end
    coc-config -.-> coc.nvim
    config.easy --> neovim
    config.manual --> neovim
    subgraph lsp.client [LSP clients]
      neovim
      coc.nvim
    end
  end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment