LSP: added elixir and formatter,

- C# added formatter
This commit is contained in:
Barna Máté 2024-12-19 22:41:52 +01:00
parent 8d284b106c
commit 2277230c16
4 changed files with 53 additions and 1 deletions

View file

@ -1,5 +1,17 @@
# 4o1x5's neovim configuration
### Language support
Many languages are supported by default with formatters and linters. A few notable:
- Rust
- Typescript
- C#
- Lua
- Python
[and much more..](./config/plugins/lang/)
## Run with nix
```bash

View file

@ -2,8 +2,21 @@
{
plugins = {
# TODO lint
lsp.servers.csharp_ls.enable = true;
conform-nvim.settings = {
formatters_by_ft = {
dotnet = [ "dotnet" ];
};
formatters = {
dotnet = {
command = "${pkgs.dotnet-sdk_8 }/bin/dotnet format";
};
};
};
# TODO lint
};
}

View file

@ -4,6 +4,7 @@
imports = [
./css.nix
./docker.nix
./elixir.nix
./html.nix
./json.nix
./lua.nix

View file

@ -0,0 +1,26 @@
{ pkgs, ... }:
{
plugins = {
lsp.servers.elixirls.enable = true;
conform-nvim.settings = {
formatters_by_ft = {
elixir = [ "elixir" ];
};
formatters = {
elixir = {
command = "${pkgs.elixir}/bin/mix format";
};
};
};
# TODO use credo to lint
#lint = {
# lintersByFt.elixir = [ "elixir" ];
# linters.elixir.cmd = "${pkgs.elixir}/bin/mix deps.get";
#};
};
}