Fork me on GitHub
#vim
<
2022-10-20
>
Paul12:10:04

Looking for a couple modules for neovim and clojure (yes I've tried googling!) -- automatic code formatting such as prettier (not sure if this is common in clojure / lisp) and structural editing. Any help is greatly appreciated.

athomasoriginal12:10:50

I use parinfer for structural editing (parinfer-rust) and for formatting, zprint. But I do formatting outside vim currently

👀 1
gratitude-thank-you 1
walterl13:10:00

guns/vim-sexp+`tpope/vim-sexp-mappings-for-regular-people` works well structural editing for me. The former also includes formatting, but so does clojure-lsp (I use Neovim's native LSP support to hook that up). Dotfiles https://github.com/walterl/dotfiles/tree/master/_config/nvim if you're interested.

gratitude-thank-you 1
dharrigan13:10:48

I've shared my vimconfig here: https://github.com/dharrigan/vimconfig. Perhaps you may find some things useful 🙂

gratitude-thank-you 2
Proctor13:10:42

There is also paredit to round out the parinfer and vim-sexp options

Aziz Aldawood05:10:18

vim-iced (which includes formatting) + parinfer-rust very very nice experience

✅ 2
Paul13:10:07

I'm currently using conjure

conjure 1
practicalli-johnny09:10:18

Automatic code formating: https://github.com/neovim/nvim-lspconfig with https://clojure-lsp.io/ server and Neovim built-in https://neovim.io/doc/user/lsp.html Manual code formatting: https://github.com/greglook/cljstyle ran on the command line, using this https://github.com/practicalli/dotfiles/blob/main/.cljstyle to match cljfmt formatting used in Clojure LSP I use these https://github.com/practicalli/neovim-config-redux#plugins (using a Fennel config)