Changes between Version 4 and Version 5 of WebKitEmacsTips


Ignore:
Timestamp:
May 23, 2022, 8:13:25 AM (3 years ago)
Author:
Philippe Normand
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • WebKitEmacsTips

    v4 v5  
    11
    2 == Enabling LSP mode
     2== Enabling the ccls LSP backend
    33
    44If you're using spacemacs, enable the c-c++ layer in `dotspacemacs-configuration-layers`:
     
    6262%cpp --include=config.h
    6363}}}
     64
     65== Enabling the clangd LSP backend
     66
     67
     68If you're using spacemacs, enable the c-c++ layer in `dotspacemacs-configuration-layers`:
     69
     70{{{
     71dotspacemacs-configuration-layers
     72   '(
     73       (c-c++ :variables
     74            c-c++-backend 'lsp-clangd
     75            c-c++-lsp-enable-semantic-highlight 'rainbow)
     76       ...
     77)
     78}}}
     79
     80And then in `dotspacemacs/user-config`:
     81
     82{{{
     83  (dir-locals-set-class-variables
     84     'webkit-instance
     85     '((nil . ((c-basic-offset . 4)
     86               (indent-tabs-mode . nil)
     87               (fill-column . 100)
     88               (lsp-clients-clangd-executable . "/home/phil/WebKit/Tools/flatpak/webkit-clangd")
     89               (lsp-clients-clangd-args . ("--enable-config"
     90                                           "--gtk"
     91                                           ))
     92               (projectile-project-name . "WebKit")
     93               (lsp-enable-file-watchers . nil)
     94               (lsp-ui-peek-find-references nil (list :folders (vector (projectile-project-root))))
     95               ))
     96        )
     97     )
     98
     99(dir-locals-set-directory-class
     100     "/home/phil/WebKit/" 'webkit-instance)
     101}}}