diff --git a/doom/.config/doom/config.el b/doom/.config/doom/config.el index 5139ee0..7edc845 100644 --- a/doom/.config/doom/config.el +++ b/doom/.config/doom/config.el @@ -46,6 +46,10 @@ ;; doesn't show in childframe, but might be useful in terminal company-show-quick-access 1)) +(after! ccls + (setq ccls-initialization-options '(:index (:comments 2) :completion (:detailedLabel t))) + (set-lsp-priority! 'ccls 2)) ; optional as ccls is the default in Doom + ;; pinentry for emacs ssh gpg (use-package! pinentry :init (setq epg-pinentry-mode `loopback) @@ -139,6 +143,15 @@ headers" (setq magit-revision-show-gravatars '("^Author: " . "^Commit: ")) +;; https://arjenwiersma.nl/posts/cleaning-up-lsp-mode/ +(defun aw/cleanup-lsp () + "Remove all the workspace folders from LSP" + (interactive) + (let ((folders (lsp-session-folders (lsp-session)))) + (while folders + (lsp-workspace-folders-remove (car folders)) + (setq folders (cdr folders))))) + ;; Whenever you reconfigure a package, make sure to wrap your config in an ;; `after!' block, otherwise Doom's defaults may override your settings. E.g. ;; diff --git a/doom/.config/doom/init.el b/doom/.config/doom/init.el index 9e7dbe0..13df073 100644 --- a/doom/.config/doom/init.el +++ b/doom/.config/doom/init.el @@ -115,7 +115,7 @@ :lang ;;agda ; types of types of types of types... ;;beancount ; mind the GAAP - ;;(cc +lsp) ; C > C++ == 1 + (cc +lsp) ; C > C++ == 1 ;;clojure ; java with a lisp ;;common-lisp ; if you've seen one lisp, you've seen them all ;;coq ; proofs-as-programs diff --git a/neovim/.config/nvim/init.vim b/neovim/.config/nvim/init.vim index 56ba96d..e940c5a 100644 --- a/neovim/.config/nvim/init.vim +++ b/neovim/.config/nvim/init.vim @@ -1,4 +1,4 @@ -set showmatch " show matching +set showmatch " show matching () {} set ignorecase " case insensitive set mouse=v " middle-click paste @@ -30,25 +30,48 @@ endif call plug#begin(stdpath('data') . '/plugged') -Plug 'nvim-lua/plenary.nvim' -Plug 'TimUntersberger/neogit' +Plug 'dracula/vim', { 'as': 'dracula' } + +Plug 'tpope/vim-sensible' Plug 'tpope/vim-fugitive' +Plug 'tpope/vim-surround' +Plug 'tpope/vim-commentary' + Plug 'editorconfig/editorconfig-vim' Plug 'wakatime/vim-wakatime' call plug#end() -lua <g :Neogit +colorscheme dracula + +" https://github.com/henrik/vim-reveal-in-finder/blob/master/plugin/reveal_in_finder.vim +function! s:RevealInFinder() + if filereadable(expand("%")) + let l:command = "open -R " . shellescape("%") + elseif getftype(expand("%:p:h")) == "dir" + let l:command = "open " . shellescape("%") . ":p:h" + else + let l:command = "open ." + endif + + execute ":silent! !" . l:command + + " For terminal Vim not to look messed up. + redraw! +endfunction + +command! Reveal call RevealInFinder() + +" Auto close, Ctrl-v to not do +ino " "" +ino ' '' +ino ( () +ino [ [] +ino { {} +ino { {}O " no ex mode nnoremap Q