mirror of
https://github.com/NotAShelf/neovim-flake.git
synced 2024-11-09 14:45:58 +01:00
Compare commits
46 commits
f56698f89f
...
74ad895f7e
Author | SHA1 | Date | |
---|---|---|---|
|
74ad895f7e | ||
9d0247c599 | |||
f0f2c08e9f | |||
cfbed8ceb1 | |||
1ce25d7ca3 | |||
eefc7a9d1d | |||
74c94b8a54 | |||
74df3a5f03 | |||
|
7224c1e6af | ||
|
f343ab8b3a | ||
|
208d1e6741 | ||
493854e44f | |||
|
cc0aba4e21 | ||
|
db810bbf9f | ||
1fd4a2a1b8 | |||
7cafa56cdb | |||
b5f38b8e5e | |||
355d4830e5 | |||
2615c568f8 | |||
407ecf00d5 | |||
7c1a8e2c1e | |||
ea5f229efd | |||
41f7abcdc3 | |||
a85bf963e6 | |||
26755a6b93 | |||
96b92b5652 | |||
544c98a03b | |||
e96897f6b3 | |||
12fd9d69dc | |||
|
dc0fa76295 | ||
e0790f2bdb | |||
bf090172d2 | |||
7481423bed | |||
6eba2a5585 | |||
1847b9f1bf | |||
d06ff3d7db | |||
|
83583e9b64 | ||
efd8b44ce1 | |||
|
9fe96ce010 | ||
a777941eed | |||
a20f84edfb | |||
|
666de6a5be | ||
|
3ad560ea30 | ||
ab2685579a | |||
|
64e79a9f4c | ||
fe9bcf224b |
46 changed files with 1236 additions and 1103 deletions
1
.github/workflows/cachix.yml
vendored
1
.github/workflows/cachix.yml
vendored
|
@ -19,7 +19,6 @@ jobs:
|
||||||
package:
|
package:
|
||||||
- default
|
- default
|
||||||
- nix
|
- nix
|
||||||
- tidal
|
|
||||||
- maximal
|
- maximal
|
||||||
steps:
|
steps:
|
||||||
- uses: easimon/maximize-build-space@v10
|
- uses: easimon/maximize-build-space@v10
|
||||||
|
|
|
@ -15,10 +15,6 @@ inputs: let
|
||||||
configuration.imports = modules;
|
configuration.imports = modules;
|
||||||
};
|
};
|
||||||
|
|
||||||
tidalConfig = {
|
|
||||||
config.vim.languages.tidal.enable = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
mainConfig = isMaximal: {
|
mainConfig = isMaximal: {
|
||||||
config.vim = {
|
config.vim = {
|
||||||
viAlias = true;
|
viAlias = true;
|
||||||
|
@ -58,7 +54,16 @@ inputs: let
|
||||||
enableTreesitter = true;
|
enableTreesitter = true;
|
||||||
enableExtraDiagnostics = true;
|
enableExtraDiagnostics = true;
|
||||||
|
|
||||||
|
# Nim LSP is broken on Darwin and therefore
|
||||||
|
# should be disabled by default. Users may still enable
|
||||||
|
# `vim.languages.vim` to enable it, this does not restrict
|
||||||
|
# that.
|
||||||
|
# See: <https://github.com/PMunch/nimlsp/issues/178#issue-2128106096>
|
||||||
|
nim.enable = false;
|
||||||
|
|
||||||
nix.enable = true;
|
nix.enable = true;
|
||||||
|
|
||||||
|
markdown.enable = isMaximal;
|
||||||
html.enable = isMaximal;
|
html.enable = isMaximal;
|
||||||
css.enable = isMaximal;
|
css.enable = isMaximal;
|
||||||
sql.enable = isMaximal;
|
sql.enable = isMaximal;
|
||||||
|
@ -66,13 +71,12 @@ inputs: let
|
||||||
ts.enable = isMaximal;
|
ts.enable = isMaximal;
|
||||||
svelte.enable = isMaximal;
|
svelte.enable = isMaximal;
|
||||||
go.enable = isMaximal;
|
go.enable = isMaximal;
|
||||||
|
elixir.enable = isMaximal;
|
||||||
zig.enable = isMaximal;
|
zig.enable = isMaximal;
|
||||||
|
ocaml.enable = isMaximal;
|
||||||
python.enable = isMaximal;
|
python.enable = isMaximal;
|
||||||
dart.enable = isMaximal;
|
dart.enable = isMaximal;
|
||||||
elixir.enable = isMaximal;
|
|
||||||
bash.enable = isMaximal;
|
bash.enable = isMaximal;
|
||||||
terraform.enable = isMaximal;
|
|
||||||
nim.enable = false;
|
|
||||||
tailwind.enable = isMaximal;
|
tailwind.enable = isMaximal;
|
||||||
typst.enable = isMaximal;
|
typst.enable = isMaximal;
|
||||||
clang = {
|
clang = {
|
||||||
|
@ -82,14 +86,14 @@ inputs: let
|
||||||
|
|
||||||
rust = {
|
rust = {
|
||||||
enable = isMaximal;
|
enable = isMaximal;
|
||||||
crates.enable = true;
|
crates.enable = isMaximal;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
visuals = {
|
visuals = {
|
||||||
enable = true;
|
enable = true;
|
||||||
nvimWebDevicons.enable = true;
|
nvimWebDevicons.enable = true;
|
||||||
scrollBar.enable = true;
|
scrollBar.enable = isMaximal;
|
||||||
smoothScroll.enable = true;
|
smoothScroll.enable = true;
|
||||||
cellularAutomaton.enable = false;
|
cellularAutomaton.enable = false;
|
||||||
fidget-nvim.enable = true;
|
fidget-nvim.enable = true;
|
||||||
|
@ -252,5 +256,5 @@ inputs: let
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
in {
|
in {
|
||||||
inherit neovimConfiguration mainConfig tidalConfig;
|
inherit neovimConfiguration mainConfig;
|
||||||
}
|
}
|
||||||
|
|
|
@ -5,7 +5,6 @@ Below are the commands you may run to try out different configurations provided
|
||||||
configurations are provided:
|
configurations are provided:
|
||||||
|
|
||||||
- Nix
|
- Nix
|
||||||
- Tidal
|
|
||||||
- Maximal
|
- Maximal
|
||||||
|
|
||||||
You may try out any of the provided configurations using the `nix run` command on a system where Nix is installed.
|
You may try out any of the provided configurations using the `nix run` command on a system where Nix is installed.
|
||||||
|
@ -22,7 +21,6 @@ once you garbage collect.
|
||||||
|
|
||||||
```console
|
```console
|
||||||
$ nix run github:notashelf/nvf#nix
|
$ nix run github:notashelf/nvf#nix
|
||||||
$ nix run github:notashelf/nvf#tidal
|
|
||||||
$ nix run github:notashelf/nvf#maximal
|
$ nix run github:notashelf/nvf#maximal
|
||||||
```
|
```
|
||||||
|
|
||||||
|
@ -33,10 +31,6 @@ $ nix run github:notashelf/nvf#maximal
|
||||||
`Nix` configuration by default provides LSP/diagnostic support for Nix alongisde a set of visual and functional plugins.
|
`Nix` configuration by default provides LSP/diagnostic support for Nix alongisde a set of visual and functional plugins.
|
||||||
By running `nix run .#`, which is the default package, you will build Neovim with this config.
|
By running `nix run .#`, which is the default package, you will build Neovim with this config.
|
||||||
|
|
||||||
#### Tidal {#sec-configs-tidal}
|
|
||||||
|
|
||||||
Tidal is an alternative config that adds vim-tidal on top of the plugins from the Nix configuration.
|
|
||||||
|
|
||||||
#### Maximal {#sec-configs-maximal}
|
#### Maximal {#sec-configs-maximal}
|
||||||
|
|
||||||
`Maximal` is the ultimate configuration that will enable support for more commonly used language as well as additional
|
`Maximal` is the ultimate configuration that will enable support for more commonly used language as well as additional
|
||||||
|
|
|
@ -6,10 +6,39 @@ Release notes for release 0.7
|
||||||
|
|
||||||
[ItsSorae](https://github.com/ItsSorae):
|
[ItsSorae](https://github.com/ItsSorae):
|
||||||
|
|
||||||
- Added support for [typst](https://typst.app/) under `vim.languages.typst`.
|
- Added support for [typst](https://typst.app/) under `vim.languages.typst` This
|
||||||
This will enable the `typst-lsp` language server, and the `typstfmt` formatter.
|
will enable the `typst-lsp` language server, and the `typstfmt` formatter
|
||||||
|
|
||||||
[frothymarrow](https://github.com/frothymarrow):
|
[frothymarrow](https://github.com/frothymarrow):
|
||||||
|
|
||||||
- Modified type for [](#opt-vim.visuals.fidget-nvim.setupOpts.progress.display.overrides)
|
- Modified type for
|
||||||
from `anything` to a `submodule` for better type checking.
|
[](#opt-vim.visuals.fidget-nvim.setupOpts.progress.display.overrides) from
|
||||||
|
`anything` to a `submodule` for better type checking.
|
||||||
|
- Fix null `vim.lsp.mappings` generating an error and not being filtered out.
|
||||||
|
|
||||||
|
[horriblename](https://github.com/horriblename):
|
||||||
|
|
||||||
|
- Fix broken treesitter-context keybinds in visual mode
|
||||||
|
|
||||||
|
[NotAShelf](https://github.com/notashelf)
|
||||||
|
|
||||||
|
- Add `deno fmt` as the default Markdown formatter. This will be enabled
|
||||||
|
automatically if you have autoformatting enabled, but can be disabled manually
|
||||||
|
if you choose to.
|
||||||
|
|
||||||
|
- Add `vim.extraLuaFiles` for optionally sourcing additional lua files in your
|
||||||
|
configuration.
|
||||||
|
|
||||||
|
- Refactor `programs.languages.elixir` to use lspconfig and none-ls for LSP and
|
||||||
|
formatter setups respectively. Diagnostics support is considered, and may be
|
||||||
|
added once the [credo](https://github.com/rrrene/credo) linter has been added
|
||||||
|
to nixpkgs. A pull request is currently open.
|
||||||
|
|
||||||
|
- Remove vim-tidal and friends
|
||||||
|
|
||||||
|
- Cleaned up Lualine module to reduce theme dependency on Catppuccin, and fixed
|
||||||
|
blending issues in component separators.
|
||||||
|
|
||||||
|
[jacekpoz](https://github.com/jacekpoz):
|
||||||
|
|
||||||
|
- Added [ocaml-lsp](https://github.com/ocaml/ocaml-lsp) support.
|
||||||
|
|
427
flake.lock
427
flake.lock
|
@ -1,22 +1,5 @@
|
||||||
{
|
{
|
||||||
"nodes": {
|
"nodes": {
|
||||||
"dirt-samples-src": {
|
|
||||||
"flake": false,
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1667426233,
|
|
||||||
"narHash": "sha256-Zl2bi9QofcrhU63eMtg+R6lhV9ExQS/0XNTJ+oq65Uo=",
|
|
||||||
"owner": "tidalcycles",
|
|
||||||
"repo": "dirt-samples",
|
|
||||||
"rev": "92f2145e661b397e62ca0ff3965819e7c7db0dad",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "tidalcycles",
|
|
||||||
"ref": "master",
|
|
||||||
"repo": "dirt-samples",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"flake-compat": {
|
"flake-compat": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
|
@ -38,11 +21,11 @@
|
||||||
"nixpkgs-lib": "nixpkgs-lib"
|
"nixpkgs-lib": "nixpkgs-lib"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1712014858,
|
"lastModified": 1714641030,
|
||||||
"narHash": "sha256-sB4SWl2lX95bExY2gMFG5HIzvva5AVMJd4Igm+GpZNw=",
|
"narHash": "sha256-yzcRNDoyVP7+SCNX0wmuDju1NUCt8Dz9+lyUXEI0dbI=",
|
||||||
"owner": "hercules-ci",
|
"owner": "hercules-ci",
|
||||||
"repo": "flake-parts",
|
"repo": "flake-parts",
|
||||||
"rev": "9126214d0a59633752a136528f5f3b9aa8565b7d",
|
"rev": "e5d10a24b66c3ea8f150e47dfdb0416ab7c3390e",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -116,11 +99,11 @@
|
||||||
"rust-overlay": "rust-overlay"
|
"rust-overlay": "rust-overlay"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1704611696,
|
"lastModified": 1714571717,
|
||||||
"narHash": "sha256-4ZCgV5oHdEc3q+XaIzy//gh20uC/aSuAtMU9bsfgLZk=",
|
"narHash": "sha256-o4tqlTzi9kcVub167kTGXgCac9jM3kW4+v9MH/ue4Hk=",
|
||||||
"owner": "oxalica",
|
"owner": "oxalica",
|
||||||
"repo": "nil",
|
"repo": "nil",
|
||||||
"rev": "059d33a24bb76d2048740bcce936362bf54b5bc9",
|
"rev": "2f3ed6348bbf1440fcd1ab0411271497a0fbbfa4",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -131,11 +114,11 @@
|
||||||
},
|
},
|
||||||
"nixpkgs": {
|
"nixpkgs": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1713895582,
|
"lastModified": 1715534503,
|
||||||
"narHash": "sha256-cfh1hi+6muQMbi9acOlju3V1gl8BEaZBXBR9jQfQi4U=",
|
"narHash": "sha256-5ZSVkFadZbFP1THataCaSf0JH2cAH3S29hU9rrxTEqk=",
|
||||||
"owner": "nixos",
|
"owner": "nixos",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "572af610f6151fd41c212f897c71f7056e3fb518",
|
"rev": "2057814051972fa1453ddfb0d98badbea9b83c06",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -147,20 +130,14 @@
|
||||||
},
|
},
|
||||||
"nixpkgs-lib": {
|
"nixpkgs-lib": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"dir": "lib",
|
"lastModified": 1714640452,
|
||||||
"lastModified": 1711703276,
|
"narHash": "sha256-QBx10+k6JWz6u7VsohfSw8g8hjdBZEf8CFzXH1/1Z94=",
|
||||||
"narHash": "sha256-iMUFArF0WCatKK6RzfUJknjem0H9m4KgorO/p3Dopkk=",
|
"type": "tarball",
|
||||||
"owner": "NixOS",
|
"url": "https://github.com/NixOS/nixpkgs/archive/50eb7ecf4cd0a5756d7275c8ba36790e5bd53e33.tar.gz"
|
||||||
"repo": "nixpkgs",
|
|
||||||
"rev": "d8fe5e6c92d0d190646fb9f1056741a229980089",
|
|
||||||
"type": "github"
|
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"dir": "lib",
|
"type": "tarball",
|
||||||
"owner": "NixOS",
|
"url": "https://github.com/NixOS/nixpkgs/archive/50eb7ecf4cd0a5756d7275c8ba36790e5bd53e33.tar.gz"
|
||||||
"ref": "nixos-unstable",
|
|
||||||
"repo": "nixpkgs",
|
|
||||||
"type": "github"
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"nixpkgs_2": {
|
"nixpkgs_2": {
|
||||||
|
@ -180,22 +157,6 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"nixpkgs_3": {
|
"nixpkgs_3": {
|
||||||
"locked": {
|
|
||||||
"lastModified": 1693844670,
|
|
||||||
"narHash": "sha256-t69F2nBB8DNQUWHD809oJZJVE+23XBrth4QZuVd6IE0=",
|
|
||||||
"owner": "NixOS",
|
|
||||||
"repo": "nixpkgs",
|
|
||||||
"rev": "3c15feef7770eb5500a4b8792623e2d6f598c9c1",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "NixOS",
|
|
||||||
"ref": "nixos-unstable",
|
|
||||||
"repo": "nixpkgs",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"nixpkgs_4": {
|
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1702350026,
|
"lastModified": 1702350026,
|
||||||
"narHash": "sha256-A+GNZFZdfl4JdDphYKBJ5Ef1HOiFsP18vQe9mqjmUis=",
|
"narHash": "sha256-A+GNZFZdfl4JdDphYKBJ5Ef1HOiFsP18vQe9mqjmUis=",
|
||||||
|
@ -262,11 +223,11 @@
|
||||||
"plugin-catppuccin": {
|
"plugin-catppuccin": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1713105352,
|
"lastModified": 1715167632,
|
||||||
"narHash": "sha256-yTVou/WArEWygBBs2NFPI9Dm9iSGfwVftKFbOAGl8tk=",
|
"narHash": "sha256-aRrhVHQSCyo1Ti1j8ogWJ8e0eJWiTw5+abIpyUxky/M=",
|
||||||
"owner": "catppuccin",
|
"owner": "catppuccin",
|
||||||
"repo": "nvim",
|
"repo": "nvim",
|
||||||
"rev": "a1439ad7c584efb3d0ce14ccb835967f030450fe",
|
"rev": "d97387aea8264f484bb5d5e74f2182a06c83e0d8",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -278,11 +239,11 @@
|
||||||
"plugin-ccc": {
|
"plugin-ccc": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1712580766,
|
"lastModified": 1714299582,
|
||||||
"narHash": "sha256-G96++Bmuklb3eDfmyKPKFUDHuopTMmIFa/ILdf11N/I=",
|
"narHash": "sha256-QRq9hQF5vLnOTzQGbOWC2ykMdMsQDlDlb6XC17dJG7Q=",
|
||||||
"owner": "uga-rosa",
|
"owner": "uga-rosa",
|
||||||
"repo": "ccc.nvim",
|
"repo": "ccc.nvim",
|
||||||
"rev": "1283eef5494c092a047baa34ed3e667f3cb2715e",
|
"rev": "f388f1981d222967c741fe9927edf9ba5fa3bcbe",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -342,11 +303,11 @@
|
||||||
"plugin-cinnamon-nvim": {
|
"plugin-cinnamon-nvim": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1711005384,
|
"lastModified": 1714107684,
|
||||||
"narHash": "sha256-LNikkGldBpUsfyH8ThtX7RS1p/z3JzSPonT9qUU84jw=",
|
"narHash": "sha256-cMP9WRZzevxaWgpILyDh1JwNukm3Jl3JKJYPT2HnFns=",
|
||||||
"owner": "declancm",
|
"owner": "declancm",
|
||||||
"repo": "cinnamon.nvim",
|
"repo": "cinnamon.nvim",
|
||||||
"rev": "559fe02fae00ffd78377e9c242b2faa25a428592",
|
"rev": "a011e84b624cd7b609ea928237505d31b987748a",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -406,11 +367,11 @@
|
||||||
"plugin-cmp-treesitter": {
|
"plugin-cmp-treesitter": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1702163214,
|
"lastModified": 1715596479,
|
||||||
"narHash": "sha256-K7F9iqmB13ONenwsbaND8F4010MvHQXp7DxMFfcsZ4A=",
|
"narHash": "sha256-8WAk9S+/7vSz7bVHdEzjbKUokU144fvnByIeJ1gAWhU=",
|
||||||
"owner": "ray-x",
|
"owner": "ray-x",
|
||||||
"repo": "cmp-treesitter",
|
"repo": "cmp-treesitter",
|
||||||
"rev": "13e4ef8f4dd5639fca2eb9150e68f47639a9b37d",
|
"rev": "958fcfa0d8ce46d215e19cc3992c542f576c4123",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -502,11 +463,11 @@
|
||||||
"plugin-crates-nvim": {
|
"plugin-crates-nvim": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1713995074,
|
"lastModified": 1715690194,
|
||||||
"narHash": "sha256-09+mBhh5hAXENPzrvwNNQEyM7ZtuPYAWrtAG/pzBOV8=",
|
"narHash": "sha256-R1y1OIep4tcFd4mhylZ/A2zdwOmEQtCzuVBOBYu0qUI=",
|
||||||
"owner": "Saecki",
|
"owner": "Saecki",
|
||||||
"repo": "crates.nvim",
|
"repo": "crates.nvim",
|
||||||
"rev": "f00e11e8282b94f2a2e938d32712c99f0e0bdeb4",
|
"rev": "d556c00d60c9421c913ee54ff690df2a34f6264e",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -518,11 +479,11 @@
|
||||||
"plugin-dashboard-nvim": {
|
"plugin-dashboard-nvim": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1713420371,
|
"lastModified": 1714906999,
|
||||||
"narHash": "sha256-zcWBgDM409n6rmb06FqVXbC+HU9HJN0+ADoTJDWHvbA=",
|
"narHash": "sha256-euIAtegnJTH2hpFP0OAuvl7VpEV0Xu91h+w9p1uC3+0=",
|
||||||
"owner": "glepnir",
|
"owner": "glepnir",
|
||||||
"repo": "dashboard-nvim",
|
"repo": "dashboard-nvim",
|
||||||
"rev": "6d06924b562de6f0bb136edf1bf549afbf6b7d00",
|
"rev": "a0a78099658c7d4be3714f657b18ca8285d5d106",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -579,30 +540,14 @@
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"plugin-elixir-ls": {
|
|
||||||
"flake": false,
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1713724318,
|
|
||||||
"narHash": "sha256-1kLMxznNRRJ7M10zkuWexA/sPFaN449M0SKUjLrnc8c=",
|
|
||||||
"owner": "elixir-lsp",
|
|
||||||
"repo": "elixir-ls",
|
|
||||||
"rev": "8486de473a219dcdb72408702f8d56d0227c7366",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "elixir-lsp",
|
|
||||||
"repo": "elixir-ls",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"plugin-elixir-tools": {
|
"plugin-elixir-tools": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1713617654,
|
"lastModified": 1714657398,
|
||||||
"narHash": "sha256-pJgtW51FLs+Yr+tlQckRmGkRnSUQNI3fEROn3D51mMs=",
|
"narHash": "sha256-U6db1n/RIpT7Dd54e9iI/PjO1BhDpMyNPfaph+dUk7k=",
|
||||||
"owner": "elixir-tools",
|
"owner": "elixir-tools",
|
||||||
"repo": "elixir-tools.nvim",
|
"repo": "elixir-tools.nvim",
|
||||||
"rev": "3c4f8344a341818417b3d75c04eb96d894cb4640",
|
"rev": "51eddb03a7a8c9f00d6415b356a4d3b75d8e75b6",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -646,11 +591,11 @@
|
||||||
"plugin-gesture-nvim": {
|
"plugin-gesture-nvim": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1713872849,
|
"lastModified": 1715211052,
|
||||||
"narHash": "sha256-npryXJ92l65gOGltTd3jE3fdhiEgqbxCdK5w/C/BQV0=",
|
"narHash": "sha256-vRXQBoKhmYid1M1d4OI/PolwQIwMn1x7EgxeW6Dzj0o=",
|
||||||
"owner": "notomo",
|
"owner": "notomo",
|
||||||
"repo": "gesture.nvim",
|
"repo": "gesture.nvim",
|
||||||
"rev": "47175ed2741ba46fe7f14d6ee37ebbc5b9614c5a",
|
"rev": "9b3d6361b37628f8869cd237416a1674103c0dc1",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -662,11 +607,11 @@
|
||||||
"plugin-gitsigns-nvim": {
|
"plugin-gitsigns-nvim": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1713620636,
|
"lastModified": 1715007445,
|
||||||
"narHash": "sha256-UK3DyvrQ0kLm9wrMQ6tLDoDunoThbY/Yfjn+eCZpuMw=",
|
"narHash": "sha256-v21qTJfiv57vSUDGCJ4wM+L0Ixwh2b3pkoESFAHBrDM=",
|
||||||
"owner": "lewis6991",
|
"owner": "lewis6991",
|
||||||
"repo": "gitsigns.nvim",
|
"repo": "gitsigns.nvim",
|
||||||
"rev": "035da036e68e509ed158414416c827d022d914bd",
|
"rev": "805610a9393fa231f2c2b49cb521bfa413fadb3d",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -694,11 +639,11 @@
|
||||||
"plugin-gruvbox": {
|
"plugin-gruvbox": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1706538659,
|
"lastModified": 1715085640,
|
||||||
"narHash": "sha256-jWnrRy/PT7D0UcPGL+XTbKHWvS0ixvbyqPtTzG9HY84=",
|
"narHash": "sha256-2Ad5I+peKCD2BCm4m/QIjqpW08qQvrY+o3bK5UEy1x8=",
|
||||||
"owner": "ellisonleao",
|
"owner": "ellisonleao",
|
||||||
"repo": "gruvbox.nvim",
|
"repo": "gruvbox.nvim",
|
||||||
"rev": "6e4027ae957cddf7b193adfaec4a8f9e03b4555f",
|
"rev": "c442515506caa166118e157980f62a9ac24fa8c3",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -710,11 +655,11 @@
|
||||||
"plugin-highlight-undo": {
|
"plugin-highlight-undo": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1713721901,
|
"lastModified": 1714982601,
|
||||||
"narHash": "sha256-5zYUpfSR56gCufR+Y18qo8ZpMRg8N3ejkRZNJswJ4wQ=",
|
"narHash": "sha256-yGw1SxcUmGQxqKhMb2SJAai07g+rOpEJy2CqIX2h9dM=",
|
||||||
"owner": "tzachar",
|
"owner": "tzachar",
|
||||||
"repo": "highlight-undo.nvim",
|
"repo": "highlight-undo.nvim",
|
||||||
"rev": "a0dbc6afa19b438ca5a6f54bc7f1a10399f21a15",
|
"rev": "1ea1c79372d7d93c88fd97543880927b7635e3d2",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -758,11 +703,11 @@
|
||||||
"plugin-image-nvim": {
|
"plugin-image-nvim": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1713989303,
|
"lastModified": 1715712794,
|
||||||
"narHash": "sha256-UBrusfIYWURI1Auo3XayswA8NXgZhqwazg6wmmgWygA=",
|
"narHash": "sha256-7mZ7a9fU/6RxnzUiYxgIsZA2wGXTalfR2cPBp6kLO3Q=",
|
||||||
"owner": "3rd",
|
"owner": "3rd",
|
||||||
"repo": "image.nvim",
|
"repo": "image.nvim",
|
||||||
"rev": "2d4b479c59fd70cc26f63d48b5cd76a44dda8873",
|
"rev": "b979fa1194443c97dd8cb6053a4cec163c9048f5",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -790,11 +735,11 @@
|
||||||
"plugin-leap-nvim": {
|
"plugin-leap-nvim": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1712927908,
|
"lastModified": 1715716911,
|
||||||
"narHash": "sha256-sSnofCInXuqaDEawT4vN1WdYl1cjK++BjSFnR1wXjr4=",
|
"narHash": "sha256-vRL++RVDywO6nP5dHQiO1NSQ17SMmHm4AgjTQfv642o=",
|
||||||
"owner": "ggandor",
|
"owner": "ggandor",
|
||||||
"repo": "leap.nvim",
|
"repo": "leap.nvim",
|
||||||
"rev": "626be4c4ec040aeaf6466c9aae17ee0ab09f1a5b",
|
"rev": "b1ecfb63c0b8babfd0dcd6b5ca6de37bbf3526cd",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -822,11 +767,11 @@
|
||||||
"plugin-lsp-signature": {
|
"plugin-lsp-signature": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1710647656,
|
"lastModified": 1715342515,
|
||||||
"narHash": "sha256-O7y7pcCvF0xUFamG+wMLe4mC6hUQ679rJV+ZUoWB0oY=",
|
"narHash": "sha256-f4AuZnt2m2VA90baSbZt6+elzjXmJKPFTO28v8auoYc=",
|
||||||
"owner": "ray-x",
|
"owner": "ray-x",
|
||||||
"repo": "lsp_signature.nvim",
|
"repo": "lsp_signature.nvim",
|
||||||
"rev": "c6aeb2f1d2538bbdfdaab1664d9d4c3c75aa9db8",
|
"rev": "aed5d1162b0f07bb3af34bedcc5f70a2b6466ed8",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -966,11 +911,11 @@
|
||||||
"plugin-noice-nvim": {
|
"plugin-noice-nvim": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1711471279,
|
"lastModified": 1715763787,
|
||||||
"narHash": "sha256-y6gHNkWVsIuwBf7MblCTKTZSqjGDxqeFeQZWexzwk94=",
|
"narHash": "sha256-sn8CiNq9JJXIxB6EEX98XaHhwyBPP7X1zqYMHLgdqd0=",
|
||||||
"owner": "folke",
|
"owner": "folke",
|
||||||
"repo": "noice.nvim",
|
"repo": "noice.nvim",
|
||||||
"rev": "0cbe3f88d038320bdbda3c4c5c95f43a13c3aa12",
|
"rev": "61947de3d5904375ea94e0c13db2537488ad9829",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -999,11 +944,11 @@
|
||||||
"plugin-nui-nvim": {
|
"plugin-nui-nvim": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1710740032,
|
"lastModified": 1714991123,
|
||||||
"narHash": "sha256-Zr5CNx6BIM6naCXW8YBc/Oj1qOtWV/3tuMoaaZjoSZA=",
|
"narHash": "sha256-W5w8mWjZhf8rhFYDJX4vPAszxKX6uLgT7+8xg3dY4Ok=",
|
||||||
"owner": "MunifTanjim",
|
"owner": "MunifTanjim",
|
||||||
"repo": "nui.nvim",
|
"repo": "nui.nvim",
|
||||||
"rev": "cbd2668414331c10039278f558630ed19b93e69b",
|
"rev": "a3597dc88b53489d3fddbddbbd13787355253bb0",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -1015,11 +960,11 @@
|
||||||
"plugin-nvim-autopairs": {
|
"plugin-nvim-autopairs": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1712441622,
|
"lastModified": 1714895218,
|
||||||
"narHash": "sha256-ta+0jw7P0ESThP8q2c+CD+nCzPMyHH2Cy3kjjysH0TE=",
|
"narHash": "sha256-LMRt1XEoeHB3blfjI0SsQr4goMUmwjoMGS2LcR3ye20=",
|
||||||
"owner": "windwp",
|
"owner": "windwp",
|
||||||
"repo": "nvim-autopairs",
|
"repo": "nvim-autopairs",
|
||||||
"rev": "4f41e5940bc0443fdbe5f995e2a596847215cd2a",
|
"rev": "14e97371b2aab6ee70054c1070a123dfaa3e217e",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -1047,11 +992,11 @@
|
||||||
"plugin-nvim-cmp": {
|
"plugin-nvim-cmp": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1713837627,
|
"lastModified": 1715507122,
|
||||||
"narHash": "sha256-rz+JMd/hsUEDNVan2sCuEGtbsOVi6oRmPtps+7qSXQE=",
|
"narHash": "sha256-wyHbTXFqvt3kXo+EaHdrEggMDOnw4enAAf4pA9ZQm2g=",
|
||||||
"owner": "hrsh7th",
|
"owner": "hrsh7th",
|
||||||
"repo": "nvim-cmp",
|
"repo": "nvim-cmp",
|
||||||
"rev": "8f3c541407e691af6163e2447f3af1bd6e17f9a3",
|
"rev": "24122371810089d390847d8ba66325c1f1aa64c0",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -1111,11 +1056,11 @@
|
||||||
"plugin-nvim-dap": {
|
"plugin-nvim-dap": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1713432622,
|
"lastModified": 1715700682,
|
||||||
"narHash": "sha256-kEn2INrNMQSLHY3gpSVV+cTx9f1nFeUCM6by9WGn5Sg=",
|
"narHash": "sha256-Gh1Vt8NLZ2MZUUB2EmTWYM0owUrpIpVyzxBgyBOwXWk=",
|
||||||
"owner": "mfussenegger",
|
"owner": "mfussenegger",
|
||||||
"repo": "nvim-dap",
|
"repo": "nvim-dap",
|
||||||
"rev": "6ae8a14828b0f3bff1721a35a1dfd604b6a933bb",
|
"rev": "559d0bbdbc4be4c7e774423061263771be1dbde8",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -1127,11 +1072,11 @@
|
||||||
"plugin-nvim-dap-ui": {
|
"plugin-nvim-dap-ui": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1710867604,
|
"lastModified": 1714314733,
|
||||||
"narHash": "sha256-KAwCt8E3lC0fzXQ9GpPsdb9wdWC6G2P4C/YFQFY9AAM=",
|
"narHash": "sha256-26g4dlxzTGaR5OrXpPo4A2erM/eSkgedb0Bl2pK362M=",
|
||||||
"owner": "rcarriga",
|
"owner": "rcarriga",
|
||||||
"repo": "nvim-dap-ui",
|
"repo": "nvim-dap-ui",
|
||||||
"rev": "edfa93f60b189e5952c016eee262d0685d838450",
|
"rev": "5934302d63d1ede12c0b22b6f23518bb183fc972",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -1175,11 +1120,11 @@
|
||||||
"plugin-nvim-lspconfig": {
|
"plugin-nvim-lspconfig": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1713908193,
|
"lastModified": 1715682701,
|
||||||
"narHash": "sha256-VdIoInJj2u49WHN4+WX0kNHdbXgh0AqIPU+OAiUaBck=",
|
"narHash": "sha256-kmo8UfTxarnxZLjL2qOeh4Jo/krxx3uqq073YnsFYxQ=",
|
||||||
"owner": "neovim",
|
"owner": "neovim",
|
||||||
"repo": "nvim-lspconfig",
|
"repo": "nvim-lspconfig",
|
||||||
"rev": "cfa386fc4027e847156ee16141ea1f4c0bc2f0a4",
|
"rev": "a27179f56c6f98a4cdcc79ee2971b514815a4940",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -1239,11 +1184,11 @@
|
||||||
"plugin-nvim-nio": {
|
"plugin-nvim-nio": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1712221544,
|
"lastModified": 1714664267,
|
||||||
"narHash": "sha256-ZRYclqsgAvlRBwb59XHlqVat7CxUJTH1rD6QLwh1ang=",
|
"narHash": "sha256-VfoJOXXtMhalFcnfhVzweq7TVmB8WjRP+Z5Z5Z24Pzc=",
|
||||||
"owner": "nvim-neotest",
|
"owner": "nvim-neotest",
|
||||||
"repo": "nvim-nio",
|
"repo": "nvim-nio",
|
||||||
"rev": "5800f585def265d52f1d8848133217c800bcb25d",
|
"rev": "8765cbc4d0c629c8158a5341e1b4305fd93c3a90",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -1271,11 +1216,11 @@
|
||||||
"plugin-nvim-session-manager": {
|
"plugin-nvim-session-manager": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1708284146,
|
"lastModified": 1715419340,
|
||||||
"narHash": "sha256-+TDWY8mprJfUp9ZFKbz83to7XW8iiovja22jHms+N1A=",
|
"narHash": "sha256-SrJJWC/newJRB879zMUbLzOJQ8qtcHfLF/7GLPFlSRQ=",
|
||||||
"owner": "Shatur",
|
"owner": "Shatur",
|
||||||
"repo": "neovim-session-manager",
|
"repo": "neovim-session-manager",
|
||||||
"rev": "d8e1ba3bbcf3fdc6a887bcfbd94c48ae4707b457",
|
"rev": "a0b9d25154be573bc0f99877afb3f57cf881cce7",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -1287,11 +1232,11 @@
|
||||||
"plugin-nvim-surround": {
|
"plugin-nvim-surround": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1712807644,
|
"lastModified": 1714506343,
|
||||||
"narHash": "sha256-gXWSCAJhOJKzTFi6QiDqDWPNgBtG5KgyF2t4gposqSY=",
|
"narHash": "sha256-PJdkmTzuRldPTdaoerdddOL0/+V/KyNSzFBBee6P4kU=",
|
||||||
"owner": "kylechui",
|
"owner": "kylechui",
|
||||||
"repo": "nvim-surround",
|
"repo": "nvim-surround",
|
||||||
"rev": "a4e30d33add8a9743b4f518b3a788b3c8e5def71",
|
"rev": "6d0dc3dbb557bcc6a024969da461df4ba803fc48",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -1303,11 +1248,11 @@
|
||||||
"plugin-nvim-tree-lua": {
|
"plugin-nvim-tree-lua": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1713946472,
|
"lastModified": 1715647490,
|
||||||
"narHash": "sha256-iD8c/dXt/UcTYDK8/zkTkFW/1Ial8ulCUWojjyXpG8k=",
|
"narHash": "sha256-YqHAEztx6gEEm0GoDXC5djnIP030oGGRcskp8LPqVoc=",
|
||||||
"owner": "nvim-tree",
|
"owner": "nvim-tree",
|
||||||
"repo": "nvim-tree.lua",
|
"repo": "nvim-tree.lua",
|
||||||
"rev": "62008e5cf2e8745c9d23bb599ef642963131057e",
|
"rev": "2bc725a3ebc23f0172fb0ab4d1134b81bcc13812",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -1319,11 +1264,11 @@
|
||||||
"plugin-nvim-treesitter-context": {
|
"plugin-nvim-treesitter-context": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1713984790,
|
"lastModified": 1715659155,
|
||||||
"narHash": "sha256-QAudKglQGDRJKrsEcMSjbrxTgQRXO60ZcfOvEnPLUoE=",
|
"narHash": "sha256-EYAIm8qicpfvOzg5xPWRwuWMPcUa/hg+q3so+s9sw5g=",
|
||||||
"owner": "nvim-treesitter",
|
"owner": "nvim-treesitter",
|
||||||
"repo": "nvim-treesitter-context",
|
"repo": "nvim-treesitter-context",
|
||||||
"rev": "4fe0a54e86859744968e1a5c7867b49c86855774",
|
"rev": "df58c81237ffe2b277e14a1692212162a34e2e2a",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -1351,11 +1296,11 @@
|
||||||
"plugin-nvim-web-devicons": {
|
"plugin-nvim-web-devicons": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1713675782,
|
"lastModified": 1715644375,
|
||||||
"narHash": "sha256-AW2W6H7OTv52hfZCcYQc5UjFArBWKLeVclrwMt13HOM=",
|
"narHash": "sha256-1trRSUVyWFl3K+7xHXQGNl/EwE0ggyigQpZ+kmRPsk8=",
|
||||||
"owner": "nvim-tree",
|
"owner": "nvim-tree",
|
||||||
"repo": "nvim-web-devicons",
|
"repo": "nvim-web-devicons",
|
||||||
"rev": "beb6367ab8496c9e43f22e0252735fdadae1872d",
|
"rev": "e37bb1feee9e7320c76050a55443fa843b4b6f83",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -1367,11 +1312,11 @@
|
||||||
"plugin-obsidian-nvim": {
|
"plugin-obsidian-nvim": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1713538455,
|
"lastModified": 1715192893,
|
||||||
"narHash": "sha256-nIAaQa0DBYBQyfTEJi3Lzqs7QJqyw0Cemq6Hm704K60=",
|
"narHash": "sha256-lGnEEFp/MU5sciq6bH5YKAiFx7kf9tTYqE+eB8zvf7A=",
|
||||||
"owner": "epwalsh",
|
"owner": "epwalsh",
|
||||||
"repo": "obsidian.nvim",
|
"repo": "obsidian.nvim",
|
||||||
"rev": "ec0f44e1921d2701bd99a542031d280f1e3930b5",
|
"rev": "2e1f03416583232899dc1b6e27673da5e705abef",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -1383,11 +1328,11 @@
|
||||||
"plugin-onedark": {
|
"plugin-onedark": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1706527208,
|
"lastModified": 1715454207,
|
||||||
"narHash": "sha256-1+aO8vrUGEe/NIVI1C1xJyuQVPQZ1s510lopkEVP7No=",
|
"narHash": "sha256-GERMsVNELbeRrKsiPeSKcwNI+bH4C79koTBRtRMGqvc=",
|
||||||
"owner": "navarasu",
|
"owner": "navarasu",
|
||||||
"repo": "onedark.nvim",
|
"repo": "onedark.nvim",
|
||||||
"rev": "1230aaf2a427b2c5b73aba6e4a9a5881d3e69429",
|
"rev": "8e4b79b0e6495ddf29552178eceba1e147e6cecf",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -1399,11 +1344,11 @@
|
||||||
"plugin-orgmode-nvim": {
|
"plugin-orgmode-nvim": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1713539113,
|
"lastModified": 1715684611,
|
||||||
"narHash": "sha256-0Ayu2kVpnsxu/ER0nx+t7nyU9oNN8URLrGQtAKKb7Ls=",
|
"narHash": "sha256-T/vjpYbrq1LTNitnSGGmguVr5UV83AFhNGmeNS2H9J0=",
|
||||||
"owner": "nvim-orgmode",
|
"owner": "nvim-orgmode",
|
||||||
"repo": "orgmode",
|
"repo": "orgmode",
|
||||||
"rev": "389e91f6f935aa845bc0cd13dd80f75431c34751",
|
"rev": "8ec0bcc6f6476d246159f738081256c97a7a9b2c",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -1431,11 +1376,11 @@
|
||||||
"plugin-plenary-nvim": {
|
"plugin-plenary-nvim": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1713788468,
|
"lastModified": 1714083960,
|
||||||
"narHash": "sha256-orGs1npIGIk7MUYadatYrcEXygK7JTj6OqQwy2TLDn0=",
|
"narHash": "sha256-vy0MXEoSM4rvYpfwbc2PnilvMOA30Urv0FAxjXuvqQ8=",
|
||||||
"owner": "nvim-lua",
|
"owner": "nvim-lua",
|
||||||
"repo": "plenary.nvim",
|
"repo": "plenary.nvim",
|
||||||
"rev": "5129a3693c482fcbc5ab99a7706ffc4360b995a0",
|
"rev": "08e301982b9a057110ede7a735dd1b5285eb341f",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -1479,11 +1424,11 @@
|
||||||
"plugin-rose-pine": {
|
"plugin-rose-pine": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1713451685,
|
"lastModified": 1715697761,
|
||||||
"narHash": "sha256-AdPSz5+nCOnLWexBasHuxRxEKbL4WVg+uV78//W5nLs=",
|
"narHash": "sha256-AdPSz5+nCOnLWexBasHuxRxEKbL4WVg+uV78//W5nLs=",
|
||||||
"owner": "rose-pine",
|
"owner": "rose-pine",
|
||||||
"repo": "neovim",
|
"repo": "neovim",
|
||||||
"rev": "17b466e79479758b332a3cac12544a3ad2be6241",
|
"rev": "b6fe88c3282cf9f117a3e836d761c2d78d02f417",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -1575,11 +1520,11 @@
|
||||||
"plugin-telescope": {
|
"plugin-telescope": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1713665692,
|
"lastModified": 1715697240,
|
||||||
"narHash": "sha256-wlRiwT1TCtwPXnIwnzqa6ZABUzJYn+lSRyvkqe6Dbsw=",
|
"narHash": "sha256-lHMbJAQ0ja2UrUantxQOVWMG502oo6QDod7AmpCw1yE=",
|
||||||
"owner": "nvim-telescope",
|
"owner": "nvim-telescope",
|
||||||
"repo": "telescope.nvim",
|
"repo": "telescope.nvim",
|
||||||
"rev": "7d1698f3d88b448e0639974248cc17f49b7b8acf",
|
"rev": "6f6bb8065567b56c42e283b06e8a1c670c0092a1",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -1671,11 +1616,11 @@
|
||||||
"plugin-vim-fugitive": {
|
"plugin-vim-fugitive": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1712554826,
|
"lastModified": 1715753556,
|
||||||
"narHash": "sha256-pmY1EQbupKvsqok9O5omkOWi0BEZ8df7HL0F7ubdY9Q=",
|
"narHash": "sha256-icKBJ/1J15h4dNS7NMfjMM/kjMPy8YMiyTI2pGTwYJY=",
|
||||||
"owner": "tpope",
|
"owner": "tpope",
|
||||||
"repo": "vim-fugitive",
|
"repo": "vim-fugitive",
|
||||||
"rev": "dac8e5c2d85926df92672bf2afb4fc48656d96c7",
|
"rev": "5b0347b5231a0f40abc311ccaf7bbf02d3ce3a5a",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -1829,7 +1774,6 @@
|
||||||
"plugin-diffview-nvim": "plugin-diffview-nvim",
|
"plugin-diffview-nvim": "plugin-diffview-nvim",
|
||||||
"plugin-dracula": "plugin-dracula",
|
"plugin-dracula": "plugin-dracula",
|
||||||
"plugin-dressing-nvim": "plugin-dressing-nvim",
|
"plugin-dressing-nvim": "plugin-dressing-nvim",
|
||||||
"plugin-elixir-ls": "plugin-elixir-ls",
|
|
||||||
"plugin-elixir-tools": "plugin-elixir-tools",
|
"plugin-elixir-tools": "plugin-elixir-tools",
|
||||||
"plugin-fidget-nvim": "plugin-fidget-nvim",
|
"plugin-fidget-nvim": "plugin-fidget-nvim",
|
||||||
"plugin-flutter-tools": "plugin-flutter-tools",
|
"plugin-flutter-tools": "plugin-flutter-tools",
|
||||||
|
@ -1906,7 +1850,6 @@
|
||||||
"plugin-which-key": "plugin-which-key",
|
"plugin-which-key": "plugin-which-key",
|
||||||
"rnix-lsp": "rnix-lsp",
|
"rnix-lsp": "rnix-lsp",
|
||||||
"systems": "systems_2",
|
"systems": "systems_2",
|
||||||
"tidalcycles": "tidalcycles",
|
|
||||||
"zig": "zig"
|
"zig": "zig"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
@ -1922,11 +1865,11 @@
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1704593904,
|
"lastModified": 1714529851,
|
||||||
"narHash": "sha256-nDoXZDTRdgF3b4n3m011y99nYFewvOl9UpzFvP8Rb3c=",
|
"narHash": "sha256-YMKJW880f7LHXVRzu93xa6Ek+QLECIu0IRQbXbzZe38=",
|
||||||
"owner": "oxalica",
|
"owner": "oxalica",
|
||||||
"repo": "rust-overlay",
|
"repo": "rust-overlay",
|
||||||
"rev": "c36fd70a99decfa6e110c86f296a97613034a680",
|
"rev": "9ca720fdcf7865385ae3b93ecdf65f1a64cb475e",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -1935,23 +1878,6 @@
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"superdirt-src": {
|
|
||||||
"flake": false,
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1611740180,
|
|
||||||
"narHash": "sha256-GtnqZeMFqFkVhgx2Exu0wY687cHa7mNnVCgjQd6fiIA=",
|
|
||||||
"owner": "musikinformatik",
|
|
||||||
"repo": "superdirt",
|
|
||||||
"rev": "7abb62e89649daa1232b9cbd6427241868abd30e",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "musikinformatik",
|
|
||||||
"ref": "master",
|
|
||||||
"repo": "superdirt",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"systems": {
|
"systems": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1681028828,
|
"lastModified": 1681028828,
|
||||||
|
@ -1982,62 +1908,6 @@
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"systems_3": {
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1681028828,
|
|
||||||
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
|
|
||||||
"owner": "nix-systems",
|
|
||||||
"repo": "default",
|
|
||||||
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "nix-systems",
|
|
||||||
"repo": "default",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"tidal-src": {
|
|
||||||
"flake": false,
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1654350756,
|
|
||||||
"narHash": "sha256-tONM5SYYBca0orTLH1EUOilSC1FCluWrFt8AetUx+YQ=",
|
|
||||||
"owner": "tidalcycles",
|
|
||||||
"repo": "tidal",
|
|
||||||
"rev": "fda9c1ecb3722698935245e5409ef8ccdfca16c8",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "tidalcycles",
|
|
||||||
"ref": "main",
|
|
||||||
"repo": "tidal",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"tidalcycles": {
|
|
||||||
"inputs": {
|
|
||||||
"dirt-samples-src": "dirt-samples-src",
|
|
||||||
"nixpkgs": "nixpkgs_3",
|
|
||||||
"superdirt-src": "superdirt-src",
|
|
||||||
"tidal-src": "tidal-src",
|
|
||||||
"utils": "utils_2",
|
|
||||||
"vim-tidal-src": "vim-tidal-src",
|
|
||||||
"vowel-src": "vowel-src"
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1694087816,
|
|
||||||
"narHash": "sha256-GMV5ONQhLwa6xRYhZkmwc2W2jbjAfHfB/OR9vR0+PFA=",
|
|
||||||
"owner": "mitchmindtree",
|
|
||||||
"repo": "tidalcycles.nix",
|
|
||||||
"rev": "1b1c4df5303e07930d23e8361ab8253ebec0c7bb",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "mitchmindtree",
|
|
||||||
"repo": "tidalcycles.nix",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"utils": {
|
"utils": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1656928814,
|
"lastModified": 1656928814,
|
||||||
|
@ -2053,69 +1923,18 @@
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"utils_2": {
|
|
||||||
"inputs": {
|
|
||||||
"systems": "systems_3"
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1692799911,
|
|
||||||
"narHash": "sha256-3eihraek4qL744EvQXsK1Ha6C3CR7nnT8X2qWap4RNk=",
|
|
||||||
"owner": "numtide",
|
|
||||||
"repo": "flake-utils",
|
|
||||||
"rev": "f9e7cf818399d17d347f847525c5a5a8032e4e44",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "numtide",
|
|
||||||
"repo": "flake-utils",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"vim-tidal-src": {
|
|
||||||
"flake": false,
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1685703852,
|
|
||||||
"narHash": "sha256-8gyk17YLeKpLpz3LRtxiwbpsIbZka9bb63nK5/9IUoA=",
|
|
||||||
"owner": "tidalcycles",
|
|
||||||
"repo": "vim-tidal",
|
|
||||||
"rev": "e440fe5bdfe07f805e21e6872099685d38e8b761",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "tidalcycles",
|
|
||||||
"repo": "vim-tidal",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"vowel-src": {
|
|
||||||
"flake": false,
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1641306144,
|
|
||||||
"narHash": "sha256-zfF6cvAGDNYWYsE8dOIo38b+dIymd17Pexg0HiPFbxM=",
|
|
||||||
"owner": "supercollider-quarks",
|
|
||||||
"repo": "vowel",
|
|
||||||
"rev": "ab59caa870201ecf2604b3efdd2196e21a8b5446",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "supercollider-quarks",
|
|
||||||
"ref": "master",
|
|
||||||
"repo": "vowel",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"zig": {
|
"zig": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"flake-compat": "flake-compat",
|
"flake-compat": "flake-compat",
|
||||||
"flake-utils": "flake-utils_2",
|
"flake-utils": "flake-utils_2",
|
||||||
"nixpkgs": "nixpkgs_4"
|
"nixpkgs": "nixpkgs_3"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1713960597,
|
"lastModified": 1715170163,
|
||||||
"narHash": "sha256-WAryNIrMfZ48iZSTh8hcHIX9vwh78LMFUtewgY7kp1Y=",
|
"narHash": "sha256-EuRzY3HI9sMMqPX7Yb7xkZaBoznP0mtS2O/Kk/r6fYk=",
|
||||||
"owner": "mitchellh",
|
"owner": "mitchellh",
|
||||||
"repo": "zig-overlay",
|
"repo": "zig-overlay",
|
||||||
"rev": "71894accd2dd096f5a84166a628b1f075311aafe",
|
"rev": "9c0a853edcab5d60d28784c10b13392d7fabb9d7",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
|
36
flake.nix
36
flake.nix
|
@ -47,7 +47,7 @@
|
||||||
nixosModules.neovim-flake has been deprecated.
|
nixosModules.neovim-flake has been deprecated.
|
||||||
Please use the nixosModules.nvf instead
|
Please use the nixosModules.nvf instead
|
||||||
''
|
''
|
||||||
self.nixosModules.neovim-flake;
|
self.nixosModules.nvf;
|
||||||
|
|
||||||
nvf = {
|
nvf = {
|
||||||
imports = [(import ./flake/modules/nixos.nix self.packages inputs)];
|
imports = [(import ./flake/modules/nixos.nix self.packages inputs)];
|
||||||
|
@ -76,6 +76,7 @@
|
||||||
|
|
||||||
# Flake inputs
|
# Flake inputs
|
||||||
inputs = {
|
inputs = {
|
||||||
|
## Basic Inputs
|
||||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
|
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
|
||||||
flake-parts.url = "github:hercules-ci/flake-parts";
|
flake-parts.url = "github:hercules-ci/flake-parts";
|
||||||
flake-utils.url = "github:numtide/flake-utils";
|
flake-utils.url = "github:numtide/flake-utils";
|
||||||
|
@ -98,13 +99,7 @@
|
||||||
inputs.flake-utils.follows = "flake-utils";
|
inputs.flake-utils.follows = "flake-utils";
|
||||||
};
|
};
|
||||||
|
|
||||||
### Plugins
|
## Plugins
|
||||||
# Tidal cycles
|
|
||||||
tidalcycles = {
|
|
||||||
url = "github:mitchmindtree/tidalcycles.nix";
|
|
||||||
inputs.vim-tidal-src.url = "github:tidalcycles/vim-tidal";
|
|
||||||
};
|
|
||||||
|
|
||||||
# LSP plugins
|
# LSP plugins
|
||||||
plugin-nvim-lspconfig = {
|
plugin-nvim-lspconfig = {
|
||||||
url = "github:neovim/nvim-lspconfig";
|
url = "github:neovim/nvim-lspconfig";
|
||||||
|
@ -183,26 +178,11 @@
|
||||||
flake = false;
|
flake = false;
|
||||||
};
|
};
|
||||||
|
|
||||||
plugin-elixir-ls = {
|
|
||||||
url = "github:elixir-lsp/elixir-ls";
|
|
||||||
flake = false;
|
|
||||||
};
|
|
||||||
|
|
||||||
plugin-elixir-tools = {
|
plugin-elixir-tools = {
|
||||||
url = "github:elixir-tools/elixir-tools.nvim";
|
url = "github:elixir-tools/elixir-tools.nvim";
|
||||||
flake = false;
|
flake = false;
|
||||||
};
|
};
|
||||||
|
|
||||||
plugin-glow-nvim = {
|
|
||||||
url = "github:ellisonleao/glow.nvim";
|
|
||||||
flake = false;
|
|
||||||
};
|
|
||||||
|
|
||||||
plugin-image-nvim = {
|
|
||||||
url = "github:3rd/image.nvim";
|
|
||||||
flake = false;
|
|
||||||
};
|
|
||||||
|
|
||||||
# Copying/Registers
|
# Copying/Registers
|
||||||
plugin-registers = {
|
plugin-registers = {
|
||||||
url = "github:tversteeg/registers.nvim";
|
url = "github:tversteeg/registers.nvim";
|
||||||
|
@ -502,6 +482,16 @@
|
||||||
flake = false;
|
flake = false;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
plugin-glow-nvim = {
|
||||||
|
url = "github:ellisonleao/glow.nvim";
|
||||||
|
flake = false;
|
||||||
|
};
|
||||||
|
|
||||||
|
plugin-image-nvim = {
|
||||||
|
url = "github:3rd/image.nvim";
|
||||||
|
flake = false;
|
||||||
|
};
|
||||||
|
|
||||||
# Note-taking
|
# Note-taking
|
||||||
plugin-obsidian-nvim = {
|
plugin-obsidian-nvim = {
|
||||||
url = "github:epwalsh/obsidian.nvim";
|
url = "github:epwalsh/obsidian.nvim";
|
||||||
|
|
|
@ -1,21 +1,11 @@
|
||||||
{lib, ...}: {
|
{lib, ...}: let
|
||||||
perSystem = {
|
inherit (lib.meta) getExe;
|
||||||
system,
|
in {
|
||||||
config,
|
perSystem = {config, ...}: {
|
||||||
...
|
apps = {
|
||||||
}: {
|
nix.program = getExe config.packages.nix;
|
||||||
apps =
|
maximal.program = getExe config.packages.maximal;
|
||||||
{
|
default = config.apps.nix;
|
||||||
nix.program = lib.getExe config.packages.nix;
|
};
|
||||||
maximal.program = lib.getExe config.packages.maximal;
|
|
||||||
default = config.apps.nix;
|
|
||||||
}
|
|
||||||
// (
|
|
||||||
if !(builtins.elem system ["aarch64-darwin" "x86_64-darwin"])
|
|
||||||
then {
|
|
||||||
tidal.program = lib.getExe config.packages.tidal;
|
|
||||||
}
|
|
||||||
else {}
|
|
||||||
);
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -7,7 +7,6 @@
|
||||||
legacyPackages = import inputs.nixpkgs {
|
legacyPackages = import inputs.nixpkgs {
|
||||||
inherit system;
|
inherit system;
|
||||||
overlays = [
|
overlays = [
|
||||||
inputs.tidalcycles.overlays.default
|
|
||||||
inputs.self.overlays.default
|
inputs.self.overlays.default
|
||||||
(_: _: {
|
(_: _: {
|
||||||
rnix-lsp = inputs'.rnix-lsp.defaultPackage;
|
rnix-lsp = inputs'.rnix-lsp.defaultPackage;
|
||||||
|
|
|
@ -6,12 +6,12 @@ packages: inputs: {
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
inherit (lib) maintainers;
|
inherit (lib) maintainers;
|
||||||
inherit (lib.modules) mkIf;
|
inherit (lib.modules) mkIf mkAliasOptionModule;
|
||||||
inherit (lib.lists) optional;
|
inherit (lib.lists) optional;
|
||||||
inherit (lib.options) mkOption mkEnableOption literalExpression;
|
inherit (lib.options) mkOption mkEnableOption literalExpression;
|
||||||
inherit (lib.types) attrsOf anything bool;
|
inherit (lib.types) attrsOf anything bool;
|
||||||
|
|
||||||
cfg = config.programs.neovim-flake;
|
cfg = config.programs.nvf;
|
||||||
inherit (import ../../configuration.nix inputs) neovimConfiguration;
|
inherit (import ../../configuration.nix inputs) neovimConfiguration;
|
||||||
|
|
||||||
neovimConfigured = neovimConfiguration {
|
neovimConfigured = neovimConfiguration {
|
||||||
|
@ -19,22 +19,26 @@ packages: inputs: {
|
||||||
modules = [cfg.settings];
|
modules = [cfg.settings];
|
||||||
};
|
};
|
||||||
in {
|
in {
|
||||||
|
imports = [
|
||||||
|
(mkAliasOptionModule ["programs" "neovim-flake"] ["programs" "nvf"])
|
||||||
|
];
|
||||||
|
|
||||||
meta.maintainers = with maintainers; [NotAShelf];
|
meta.maintainers = with maintainers; [NotAShelf];
|
||||||
|
|
||||||
options.programs.neovim-flake = {
|
options.programs.nvf = {
|
||||||
enable = mkEnableOption "neovim-flake, the extensible neovim configuration wrapper";
|
enable = mkEnableOption "nvf, the extensible neovim configuration wrapper";
|
||||||
|
|
||||||
enableManpages = mkOption {
|
enableManpages = mkOption {
|
||||||
type = bool;
|
type = bool;
|
||||||
default = false;
|
default = false;
|
||||||
description = "Whether to enable manpages for neovim-flake.";
|
description = "Whether to enable manpages for nvf.";
|
||||||
};
|
};
|
||||||
|
|
||||||
defaultEditor = mkOption {
|
defaultEditor = mkOption {
|
||||||
type = bool;
|
type = bool;
|
||||||
default = false;
|
default = false;
|
||||||
description = ''
|
description = ''
|
||||||
Whether to set `neovim-flake` as the default editor.
|
Whether to set `nvf` as the default editor.
|
||||||
|
|
||||||
This will set the `EDITOR` environment variable as `nvim`
|
This will set the `EDITOR` environment variable as `nvim`
|
||||||
if set to true.
|
if set to true.
|
||||||
|
@ -46,14 +50,14 @@ in {
|
||||||
visible = false;
|
visible = false;
|
||||||
readOnly = true;
|
readOnly = true;
|
||||||
description = ''
|
description = ''
|
||||||
The built neovim-flake package, wrapped with the user's configuration.
|
The built nvf package, wrapped with the user's configuration.
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
settings = mkOption {
|
settings = mkOption {
|
||||||
type = attrsOf anything;
|
type = attrsOf anything;
|
||||||
default = {};
|
default = {};
|
||||||
description = "Attribute set of neovim-flake preferences.";
|
description = "Attribute set of nvf preferences.";
|
||||||
example = literalExpression ''
|
example = literalExpression ''
|
||||||
{
|
{
|
||||||
vim.viAlias = false;
|
vim.viAlias = false;
|
||||||
|
@ -75,7 +79,7 @@ in {
|
||||||
};
|
};
|
||||||
|
|
||||||
config = mkIf cfg.enable {
|
config = mkIf cfg.enable {
|
||||||
programs.neovim-flake.finalPackage = neovimConfigured.neovim;
|
programs.nvf.finalPackage = neovimConfigured.neovim;
|
||||||
|
|
||||||
home = {
|
home = {
|
||||||
sessionVariables = mkIf cfg.defaultEditor {EDITOR = "nvim";};
|
sessionVariables = mkIf cfg.defaultEditor {EDITOR = "nvim";};
|
||||||
|
|
|
@ -6,12 +6,12 @@ packages: inputs: {
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
inherit (lib) maintainers;
|
inherit (lib) maintainers;
|
||||||
inherit (lib.modules) mkIf mkOverride;
|
inherit (lib.modules) mkIf mkOverride mkAliasOptionModule;
|
||||||
inherit (lib.lists) optional;
|
inherit (lib.lists) optional;
|
||||||
inherit (lib.options) mkOption mkEnableOption literalExpression;
|
inherit (lib.options) mkOption mkEnableOption literalExpression;
|
||||||
inherit (lib.types) attrsOf anything bool;
|
inherit (lib.types) attrsOf anything bool;
|
||||||
|
|
||||||
cfg = config.programs.neovim-flake;
|
cfg = config.programs.nvf;
|
||||||
inherit (import ../../configuration.nix inputs) neovimConfiguration;
|
inherit (import ../../configuration.nix inputs) neovimConfiguration;
|
||||||
|
|
||||||
neovimConfigured = neovimConfiguration {
|
neovimConfigured = neovimConfiguration {
|
||||||
|
@ -19,22 +19,26 @@ packages: inputs: {
|
||||||
modules = [cfg.settings];
|
modules = [cfg.settings];
|
||||||
};
|
};
|
||||||
in {
|
in {
|
||||||
|
imports = [
|
||||||
|
(mkAliasOptionModule ["programs" "neovim-flake"] ["programs" "nvf"])
|
||||||
|
];
|
||||||
|
|
||||||
meta.maintainers = with maintainers; [NotAShelf];
|
meta.maintainers = with maintainers; [NotAShelf];
|
||||||
|
|
||||||
options.programs.neovim-flake = {
|
options.programs.nvf = {
|
||||||
enable = mkEnableOption "neovim-flake, the extensible neovim configuration wrapper";
|
enable = mkEnableOption "nvf, the extensible neovim configuration wrapper";
|
||||||
|
|
||||||
enableManpages = mkOption {
|
enableManpages = mkOption {
|
||||||
type = bool;
|
type = bool;
|
||||||
default = false;
|
default = false;
|
||||||
description = "Whether to enable manpages for neovim-flake.";
|
description = "Whether to enable manpages for nvf.";
|
||||||
};
|
};
|
||||||
|
|
||||||
defaultEditor = mkOption {
|
defaultEditor = mkOption {
|
||||||
type = bool;
|
type = bool;
|
||||||
default = false;
|
default = false;
|
||||||
description = ''
|
description = ''
|
||||||
Whether to set `neovim-flake` as the default editor.
|
Whether to set `nvf` as the default editor.
|
||||||
|
|
||||||
This will set the `EDITOR` environment variable as `nvim`
|
This will set the `EDITOR` environment variable as `nvim`
|
||||||
if set to true.
|
if set to true.
|
||||||
|
@ -46,14 +50,14 @@ in {
|
||||||
visible = false;
|
visible = false;
|
||||||
readOnly = true;
|
readOnly = true;
|
||||||
description = ''
|
description = ''
|
||||||
The built neovim-flake package, wrapped with the user's configuration.
|
The built nvf package, wrapped with the user's configuration.
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
settings = mkOption {
|
settings = mkOption {
|
||||||
type = attrsOf anything;
|
type = attrsOf anything;
|
||||||
default = {};
|
default = {};
|
||||||
description = "Attribute set of neovim-flake preferences.";
|
description = "Attribute set of nvf preferences.";
|
||||||
example = literalExpression ''
|
example = literalExpression ''
|
||||||
{
|
{
|
||||||
vim.viAlias = false;
|
vim.viAlias = false;
|
||||||
|
@ -75,7 +79,7 @@ in {
|
||||||
};
|
};
|
||||||
|
|
||||||
config = mkIf cfg.enable {
|
config = mkIf cfg.enable {
|
||||||
programs.neovim-flake.finalPackage = neovimConfigured.neovim;
|
programs.nvf.finalPackage = neovimConfigured.neovim;
|
||||||
|
|
||||||
environment = {
|
environment = {
|
||||||
variables.EDITOR = mkIf cfg.defaultEditor (mkOverride 900 "nvim");
|
variables.EDITOR = mkIf cfg.defaultEditor (mkOverride 900 "nvim");
|
||||||
|
|
|
@ -9,13 +9,11 @@
|
||||||
|
|
||||||
nixConfig = mainConfig false;
|
nixConfig = mainConfig false;
|
||||||
maximalConfig = mainConfig true;
|
maximalConfig = mainConfig true;
|
||||||
tidalConfig = {config.vim.tidal.enable = true;};
|
|
||||||
in {
|
in {
|
||||||
flake.overlays.default = _final: prev: {
|
flake.overlays.default = _final: prev: {
|
||||||
inherit neovimConfiguration;
|
inherit neovimConfiguration;
|
||||||
neovim-nix = buildPkg prev [nixConfig];
|
neovim-nix = buildPkg prev [nixConfig];
|
||||||
neovim-maximal = buildPkg prev [maximalConfig];
|
neovim-maximal = buildPkg prev [maximalConfig];
|
||||||
neovim-tidal = buildPkg prev [tidalConfig];
|
|
||||||
devPkg = buildPkg pkgs [nixConfig {config.vim.languages.html.enable = pkgs.lib.mkForce true;}];
|
devPkg = buildPkg pkgs [nixConfig {config.vim.languages.html.enable = pkgs.lib.mkForce true;}];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -7,56 +7,50 @@
|
||||||
}: let
|
}: let
|
||||||
docs = import ../docs {inherit pkgs inputs;};
|
docs = import ../docs {inherit pkgs inputs;};
|
||||||
in {
|
in {
|
||||||
packages =
|
packages = {
|
||||||
{
|
# Documentation
|
||||||
# Documentation
|
docs = docs.manual.html;
|
||||||
docs = docs.manual.html;
|
docs-html = docs.manual.html;
|
||||||
docs-html = docs.manual.html;
|
docs-manpages = docs.manPages;
|
||||||
docs-manpages = docs.manPages;
|
docs-json = docs.options.json;
|
||||||
docs-json = docs.options.json;
|
|
||||||
|
|
||||||
# Build and open the built manual in your system browser
|
# Build and open the built manual in your system browser
|
||||||
docs-html-wrapped = pkgs.writeScriptBin "docs-html-wrapped" ''
|
docs-html-wrapped = pkgs.writeScriptBin "docs-html-wrapped" ''
|
||||||
#!${pkgs.stdenv.shell}
|
#!${pkgs.stdenv.shell}
|
||||||
# use xdg-open to open the docs in the browser
|
# use xdg-open to open the docs in the browser
|
||||||
${pkgs.xdg_utils}/bin/xdg-open ${docs.manual.html}
|
${pkgs.xdg_utils}/bin/xdg-open ${docs.manual.html}
|
||||||
'';
|
'';
|
||||||
|
|
||||||
# Exposed neovim configurations
|
# Exposed neovim configurations
|
||||||
nix = config.legacyPackages.neovim-nix;
|
nix = config.legacyPackages.neovim-nix;
|
||||||
maximal = config.legacyPackages.neovim-maximal;
|
maximal = config.legacyPackages.neovim-maximal;
|
||||||
default = config.legacyPackages.neovim-nix;
|
default = config.legacyPackages.neovim-nix;
|
||||||
|
|
||||||
# Published docker images
|
# Published docker images
|
||||||
docker-nix = let
|
docker-nix = let
|
||||||
inherit (pkgs) bash gitFull buildEnv dockerTools;
|
inherit (pkgs) bash gitFull buildEnv dockerTools;
|
||||||
inherit (config.legacyPackages) neovim-nix;
|
inherit (config.legacyPackages) neovim-nix;
|
||||||
in
|
in
|
||||||
dockerTools.buildImage {
|
dockerTools.buildImage {
|
||||||
name = "nvf";
|
name = "nvf";
|
||||||
tag = "latest";
|
tag = "latest";
|
||||||
|
|
||||||
copyToRoot = buildEnv {
|
copyToRoot = buildEnv {
|
||||||
name = "neovim-root";
|
name = "neovim-root";
|
||||||
pathsToLink = ["/bin"];
|
pathsToLink = ["/bin"];
|
||||||
paths = [
|
paths = [
|
||||||
neovim-nix
|
neovim-nix
|
||||||
gitFull
|
gitFull
|
||||||
bash
|
bash
|
||||||
];
|
];
|
||||||
};
|
|
||||||
|
|
||||||
config = {
|
|
||||||
Cmd = ["${neovim-nix}/bin/nvim"];
|
|
||||||
WorkingDir = "/home/neovim/demo";
|
|
||||||
Volumes = {"/home/neovim/demo" = {};};
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
}
|
|
||||||
// (
|
config = {
|
||||||
if !(builtins.elem system ["aarch64-darwin" "x86_64-darwin"])
|
Cmd = ["${neovim-nix}/bin/nvim"];
|
||||||
then {tidal = config.legacyPackages.neovim-tidal;}
|
WorkingDir = "/home/neovim/demo";
|
||||||
else {}
|
Volumes = {"/home/neovim/demo" = {};};
|
||||||
);
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -77,8 +77,7 @@ in rec {
|
||||||
else "[${toLuaObject n}] = " + (toLuaObject v))
|
else "[${toLuaObject n}] = " + (toLuaObject v))
|
||||||
(filterAttrs
|
(filterAttrs
|
||||||
(
|
(
|
||||||
_: v:
|
_: v: (toLuaObject v != "{}")
|
||||||
(v != null) && (toLuaObject v != "{}")
|
|
||||||
)
|
)
|
||||||
args)))
|
args)))
|
||||||
+ "}"
|
+ "}"
|
||||||
|
|
|
@ -25,7 +25,7 @@ inputs: {
|
||||||
# check can be disabled while calling this file is called
|
# check can be disabled while calling this file is called
|
||||||
# to avoid checking in all modules
|
# to avoid checking in all modules
|
||||||
nvimModules = import ./modules.nix {
|
nvimModules = import ./modules.nix {
|
||||||
inherit check pkgs;
|
inherit pkgs check;
|
||||||
lib = extendedLib;
|
lib = extendedLib;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
11
modules/extra/deprecations.nix
Normal file
11
modules/extra/deprecations.nix
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
{lib, ...}: let
|
||||||
|
inherit (lib.modules) mkRemovedOptionModule;
|
||||||
|
in {
|
||||||
|
imports = [
|
||||||
|
# 2024-06-06
|
||||||
|
(mkRemovedOptionModule ["vim" "tidal"] ''
|
||||||
|
Tidalcycles language support has been removed as of 2024-06-06 as it was long unmaintained. If
|
||||||
|
you depended on this functionality, please open an issue.
|
||||||
|
'')
|
||||||
|
];
|
||||||
|
}
|
|
@ -1,7 +1,7 @@
|
||||||
{
|
{
|
||||||
|
check ? true,
|
||||||
pkgs,
|
pkgs,
|
||||||
lib,
|
lib,
|
||||||
check ? true,
|
|
||||||
}: let
|
}: let
|
||||||
inherit (lib.modules) mkDefault;
|
inherit (lib.modules) mkDefault;
|
||||||
inherit (lib.lists) concatLists;
|
inherit (lib.lists) concatLists;
|
||||||
|
@ -53,7 +53,13 @@
|
||||||
"warnings"
|
"warnings"
|
||||||
];
|
];
|
||||||
|
|
||||||
allModules = concatLists [neovim plugins wrapper];
|
# Extra modules, such as deprecation warnings
|
||||||
|
# or renames in one place.
|
||||||
|
extra = map (p: ./extra + "/${p}") [
|
||||||
|
"deprecations.nix"
|
||||||
|
];
|
||||||
|
|
||||||
|
allModules = concatLists [neovim plugins wrapper extra];
|
||||||
|
|
||||||
pkgsModule = {config, ...}: {
|
pkgsModule = {config, ...}: {
|
||||||
config = {
|
config = {
|
||||||
|
|
|
@ -1,15 +1,17 @@
|
||||||
{
|
{
|
||||||
pkgs,
|
|
||||||
config,
|
config,
|
||||||
|
pkgs,
|
||||||
lib,
|
lib,
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
inherit (builtins) attrNames;
|
inherit (builtins) attrNames;
|
||||||
inherit (lib.options) mkOption mkEnableOption literalExpression;
|
inherit (lib.options) mkOption mkEnableOption literalExpression;
|
||||||
|
inherit (lib.modules) mkIf mkMerge;
|
||||||
inherit (lib.lists) isList;
|
inherit (lib.lists) isList;
|
||||||
inherit (lib.types) enum either package listOf str bool;
|
inherit (lib.types) enum either package listOf str bool;
|
||||||
inherit (lib.nvim.lua) expToLua;
|
inherit (lib.nvim.languages) diagnosticsToLua;
|
||||||
inherit (lib.nvim.types) diagnostics mkGrammarOption;
|
inherit (lib.nvim.types) diagnostics mkGrammarOption;
|
||||||
|
inherit (lib.nvim.lua) expToLua;
|
||||||
|
|
||||||
cfg = config.vim.languages.bash;
|
cfg = config.vim.languages.bash;
|
||||||
|
|
||||||
|
@ -55,6 +57,7 @@
|
||||||
ls_sources,
|
ls_sources,
|
||||||
null_ls.builtins.diagnostics.shellcheck.with({
|
null_ls.builtins.diagnostics.shellcheck.with({
|
||||||
command = "${pkg}/bin/shellcheck",
|
command = "${pkg}/bin/shellcheck",
|
||||||
|
diagnostics_format = "#{m} [#{c}]"
|
||||||
})
|
})
|
||||||
)
|
)
|
||||||
'';
|
'';
|
||||||
|
@ -114,4 +117,30 @@ in {
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
config = mkIf cfg.enable (mkMerge [
|
||||||
|
(mkIf cfg.treesitter.enable {
|
||||||
|
vim.treesitter.enable = true;
|
||||||
|
vim.treesitter.grammars = [cfg.treesitter.package];
|
||||||
|
})
|
||||||
|
|
||||||
|
(mkIf cfg.lsp.enable {
|
||||||
|
vim.lsp.lspconfig.enable = true;
|
||||||
|
vim.lsp.lspconfig.sources.bash-lsp = servers.${cfg.lsp.server}.lspConfig;
|
||||||
|
})
|
||||||
|
|
||||||
|
(mkIf cfg.format.enable {
|
||||||
|
vim.lsp.null-ls.enable = true;
|
||||||
|
vim.lsp.null-ls.sources.bash-format = formats.${cfg.format.type}.nullConfig;
|
||||||
|
})
|
||||||
|
|
||||||
|
(mkIf cfg.extraDiagnostics.enable {
|
||||||
|
vim.lsp.null-ls.enable = true;
|
||||||
|
vim.lsp.null-ls.sources = diagnosticsToLua {
|
||||||
|
lang = "bash";
|
||||||
|
config = cfg.extraDiagnostics.types;
|
||||||
|
inherit diagnosticsProviders;
|
||||||
|
};
|
||||||
|
})
|
||||||
|
]);
|
||||||
}
|
}
|
|
@ -1,83 +0,0 @@
|
||||||
{
|
|
||||||
pkgs,
|
|
||||||
config,
|
|
||||||
lib,
|
|
||||||
...
|
|
||||||
}: let
|
|
||||||
inherit (lib.lists) isList;
|
|
||||||
inherit (lib.modules) mkIf mkMerge;
|
|
||||||
inherit (lib.nvim.lua) expToLua;
|
|
||||||
inherit (lib.nvim.languages) diagnosticsToLua;
|
|
||||||
|
|
||||||
cfg = config.vim.languages.bash;
|
|
||||||
diagnosticsProviders = {
|
|
||||||
shellcheck = {
|
|
||||||
package = pkgs.shellcheck;
|
|
||||||
nullConfig = pkg: ''
|
|
||||||
table.insert(
|
|
||||||
ls_sources,
|
|
||||||
null_ls.builtins.diagnostics.shellcheck.with({
|
|
||||||
command = "${pkg}/bin/shellcheck",
|
|
||||||
})
|
|
||||||
)
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
formats = {
|
|
||||||
shfmt = {
|
|
||||||
package = pkgs.shfmt;
|
|
||||||
nullConfig = ''
|
|
||||||
table.insert(
|
|
||||||
ls_sources,
|
|
||||||
null_ls.builtins.formatting.shfmt.with({
|
|
||||||
command = "${pkgs.shfmt}/bin/shfmt",
|
|
||||||
})
|
|
||||||
)
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
servers = {
|
|
||||||
bash-ls = {
|
|
||||||
package = pkgs.nodePackages.bash-language-server;
|
|
||||||
lspConfig = ''
|
|
||||||
lspconfig.bashls.setup{
|
|
||||||
capabilities = capabilities;
|
|
||||||
on_attach = default_on_attach;
|
|
||||||
cmd = ${
|
|
||||||
if isList cfg.lsp.package
|
|
||||||
then expToLua cfg.lsp.package
|
|
||||||
else ''{"${cfg.lsp.package}/bin/bash-language-server", "start"}''
|
|
||||||
};
|
|
||||||
}
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
};
|
|
||||||
in {
|
|
||||||
config = mkIf cfg.enable (mkMerge [
|
|
||||||
(mkIf cfg.treesitter.enable {
|
|
||||||
vim.treesitter.enable = true;
|
|
||||||
vim.treesitter.grammars = [cfg.treesitter.package];
|
|
||||||
})
|
|
||||||
|
|
||||||
(mkIf cfg.lsp.enable {
|
|
||||||
vim.lsp.lspconfig.enable = true;
|
|
||||||
vim.lsp.lspconfig.sources.bash-lsp = servers.${cfg.lsp.server}.lspConfig;
|
|
||||||
})
|
|
||||||
|
|
||||||
(mkIf cfg.format.enable {
|
|
||||||
vim.lsp.null-ls.enable = true;
|
|
||||||
vim.lsp.null-ls.sources.bash-format = formats.${cfg.format.type}.nullConfig;
|
|
||||||
})
|
|
||||||
|
|
||||||
(mkIf cfg.extraDiagnostics.enable {
|
|
||||||
vim.lsp.null-ls.enable = true;
|
|
||||||
vim.lsp.null-ls.sources = diagnosticsToLua {
|
|
||||||
lang = "bash";
|
|
||||||
config = cfg.extraDiagnostics.types;
|
|
||||||
inherit diagnosticsProviders;
|
|
||||||
};
|
|
||||||
})
|
|
||||||
]);
|
|
||||||
}
|
|
|
@ -1,6 +0,0 @@
|
||||||
{
|
|
||||||
imports = [
|
|
||||||
./bash.nix
|
|
||||||
./config.nix
|
|
||||||
];
|
|
||||||
}
|
|
|
@ -1,18 +1,23 @@
|
||||||
{
|
{
|
||||||
config,
|
config,
|
||||||
lib,
|
|
||||||
pkgs,
|
pkgs,
|
||||||
|
lib,
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
inherit (builtins) attrNames;
|
inherit (builtins) attrNames;
|
||||||
|
inherit (lib.modules) mkIf mkMerge;
|
||||||
|
inherit (lib.trivial) boolToString;
|
||||||
inherit (lib.lists) isList;
|
inherit (lib.lists) isList;
|
||||||
inherit (lib.options) mkEnableOption mkOption;
|
inherit (lib.options) mkEnableOption mkOption;
|
||||||
inherit (lib.types) enum either listOf package nullOr str bool;
|
inherit (lib.types) enum either listOf package nullOr str bool;
|
||||||
inherit (lib.strings) optionalString;
|
inherit (lib.strings) optionalString;
|
||||||
inherit (lib.nvim.lua) expToLua;
|
inherit (lib.nvim.lua) expToLua;
|
||||||
inherit (lib.nvim.types) mkGrammarOption;
|
inherit (lib.nvim.types) mkGrammarOption;
|
||||||
|
inherit (lib.nvim.dag) entryAnywhere;
|
||||||
|
|
||||||
cfg = config.vim.languages.dart;
|
cfg = config.vim.languages.dart;
|
||||||
|
ftcfg = cfg.flutter-tools;
|
||||||
|
|
||||||
defaultServer = "dart";
|
defaultServer = "dart";
|
||||||
servers = {
|
servers = {
|
||||||
dart = {
|
dart = {
|
||||||
|
@ -48,15 +53,16 @@ in {
|
||||||
default = defaultServer;
|
default = defaultServer;
|
||||||
};
|
};
|
||||||
package = mkOption {
|
package = mkOption {
|
||||||
description = "Dart LSP server package, or the command to run as a list of strings";
|
|
||||||
example = ''[lib.getExe pkgs.jdt-language-server "-data" "~/.cache/jdtls/workspace"]'';
|
|
||||||
type = either package (listOf str);
|
type = either package (listOf str);
|
||||||
default = servers.${cfg.lsp.server}.package;
|
default = servers.${cfg.lsp.server}.package;
|
||||||
|
example = ''[lib.getExe pkgs.jdt-language-server "-data" "~/.cache/jdtls/workspace"]'';
|
||||||
|
description = "Dart LSP server package, or the command to run as a list of strings";
|
||||||
};
|
};
|
||||||
|
|
||||||
opts = mkOption {
|
opts = mkOption {
|
||||||
description = "Options to pass to Dart LSP server";
|
|
||||||
type = nullOr str;
|
type = nullOr str;
|
||||||
default = null;
|
default = null;
|
||||||
|
description = "Options to pass to Dart LSP server";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -70,23 +76,26 @@ in {
|
||||||
|
|
||||||
flutter-tools = {
|
flutter-tools = {
|
||||||
enable = mkOption {
|
enable = mkOption {
|
||||||
description = "Enable flutter-tools for flutter support";
|
|
||||||
type = bool;
|
type = bool;
|
||||||
default = config.vim.languages.enableLSP;
|
default = config.vim.languages.enableLSP;
|
||||||
|
description = "Enable flutter-tools for flutter support";
|
||||||
};
|
};
|
||||||
|
|
||||||
enableNoResolvePatch = mkOption {
|
enableNoResolvePatch = mkOption {
|
||||||
description = ''
|
|
||||||
Patch flutter-tools so that it doesn't resolve symlinks when detecting flutter path.
|
|
||||||
This is required if you want to use a flutter package built with nix.
|
|
||||||
If you are using a flutter SDK installed from a different source and encounter the error "`dart` missing from PATH", disable this option.
|
|
||||||
'';
|
|
||||||
type = bool;
|
type = bool;
|
||||||
default = true;
|
default = true;
|
||||||
|
description = ''
|
||||||
|
Whether to patch flutter-tools so that it doesn't resolve
|
||||||
|
symlinks when detecting flutter path.
|
||||||
|
|
||||||
|
This is required if you want to use a flutter package built with nix.
|
||||||
|
If you are using a flutter SDK installed from a different source
|
||||||
|
and encounter the error "`dart` missing from PATH", disable this option.
|
||||||
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
color = {
|
color = {
|
||||||
enable = mkEnableOption "Whether or mot to highlight color variables at all";
|
enable = mkEnableOption "highlighting color variables";
|
||||||
|
|
||||||
highlightBackground = mkOption {
|
highlightBackground = mkOption {
|
||||||
type = bool;
|
type = bool;
|
||||||
|
@ -112,4 +121,47 @@ in {
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
config = mkIf cfg.enable (mkMerge [
|
||||||
|
(mkIf cfg.treesitter.enable {
|
||||||
|
vim.treesitter.enable = true;
|
||||||
|
vim.treesitter.grammars = [cfg.treesitter.package];
|
||||||
|
})
|
||||||
|
|
||||||
|
(mkIf cfg.lsp.enable {
|
||||||
|
vim.lsp.lspconfig.enable = true;
|
||||||
|
|
||||||
|
vim.lsp.lspconfig.sources.dart-lsp = servers.${cfg.lsp.server}.lspConfig;
|
||||||
|
})
|
||||||
|
|
||||||
|
(mkIf ftcfg.enable {
|
||||||
|
vim.startPlugins =
|
||||||
|
if ftcfg.enableNoResolvePatch
|
||||||
|
then ["flutter-tools-patched"]
|
||||||
|
else ["flutter-tools"];
|
||||||
|
|
||||||
|
vim.luaConfigRC.flutter-tools = entryAnywhere ''
|
||||||
|
require('flutter-tools').setup {
|
||||||
|
lsp = {
|
||||||
|
color = { -- show the derived colours for dart variables
|
||||||
|
enabled = ${boolToString ftcfg.color.enable}, -- whether or not to highlight color variables at all, only supported on flutter >= 2.10
|
||||||
|
background = ${boolToString ftcfg.color.highlightBackground}, -- highlight the background
|
||||||
|
foreground = ${boolToString ftcfg.color.highlightForeground}, -- highlight the foreground
|
||||||
|
virtual_text = ${boolToString ftcfg.color.virtualText.enable}, -- show the highlight using virtual text
|
||||||
|
virtual_text_str = ${ftcfg.color.virtualText.character} -- the virtual text character to highlight
|
||||||
|
},
|
||||||
|
|
||||||
|
capabilities = capabilities,
|
||||||
|
on_attach = default_on_attach;
|
||||||
|
flags = lsp_flags,
|
||||||
|
},
|
||||||
|
${optionalString cfg.dap.enable ''
|
||||||
|
debugger = {
|
||||||
|
enabled = true,
|
||||||
|
},
|
||||||
|
''}
|
||||||
|
}
|
||||||
|
'';
|
||||||
|
})
|
||||||
|
]);
|
||||||
}
|
}
|
|
@ -1,76 +0,0 @@
|
||||||
{
|
|
||||||
config,
|
|
||||||
lib,
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}: let
|
|
||||||
inherit (lib.lists) isList;
|
|
||||||
inherit (lib.modules) mkIf mkMerge;
|
|
||||||
inherit (lib.strings) optionalString;
|
|
||||||
inherit (lib.trivial) boolToString;
|
|
||||||
inherit (lib.nvim.lua) expToLua;
|
|
||||||
inherit (lib.nvim.dag) entryAnywhere;
|
|
||||||
|
|
||||||
cfg = config.vim.languages.dart;
|
|
||||||
ftcfg = cfg.flutter-tools;
|
|
||||||
servers = {
|
|
||||||
dart = {
|
|
||||||
package = pkgs.dart;
|
|
||||||
lspConfig = ''
|
|
||||||
lspconfig.dartls.setup{
|
|
||||||
capabilities = capabilities;
|
|
||||||
on_attach=default_on_attach;
|
|
||||||
cmd = ${
|
|
||||||
if isList cfg.lsp.package
|
|
||||||
then expToLua cfg.lsp.package
|
|
||||||
else ''{"${cfg.lsp.package}/bin/dart", "language-server", "--protocol=lsp"}''
|
|
||||||
};
|
|
||||||
${optionalString (cfg.lsp.opts != null) "init_options = ${cfg.lsp.dartOpts}"}
|
|
||||||
}
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
};
|
|
||||||
in {
|
|
||||||
config = mkIf cfg.enable (mkMerge [
|
|
||||||
(mkIf cfg.treesitter.enable {
|
|
||||||
vim.treesitter.enable = true;
|
|
||||||
vim.treesitter.grammars = [cfg.treesitter.package];
|
|
||||||
})
|
|
||||||
|
|
||||||
(mkIf cfg.lsp.enable {
|
|
||||||
vim.lsp.lspconfig.enable = true;
|
|
||||||
|
|
||||||
vim.lsp.lspconfig.sources.dart-lsp = servers.${cfg.lsp.server}.lspConfig;
|
|
||||||
})
|
|
||||||
|
|
||||||
(mkIf ftcfg.enable {
|
|
||||||
vim.startPlugins =
|
|
||||||
if ftcfg.enableNoResolvePatch
|
|
||||||
then ["flutter-tools-patched"]
|
|
||||||
else ["flutter-tools"];
|
|
||||||
|
|
||||||
vim.luaConfigRC.flutter-tools = entryAnywhere ''
|
|
||||||
require('flutter-tools').setup {
|
|
||||||
lsp = {
|
|
||||||
color = { -- show the derived colours for dart variables
|
|
||||||
enabled = ${boolToString ftcfg.color.enable}, -- whether or not to highlight color variables at all, only supported on flutter >= 2.10
|
|
||||||
background = ${boolToString ftcfg.color.highlightBackground}, -- highlight the background
|
|
||||||
foreground = ${boolToString ftcfg.color.highlightForeground}, -- highlight the foreground
|
|
||||||
virtual_text = ${boolToString ftcfg.color.virtualText.enable}, -- show the highlight using virtual text
|
|
||||||
virtual_text_str = ${ftcfg.color.virtualText.character} -- the virtual text character to highlight
|
|
||||||
},
|
|
||||||
|
|
||||||
capabilities = capabilities,
|
|
||||||
on_attach = default_on_attach;
|
|
||||||
flags = lsp_flags,
|
|
||||||
},
|
|
||||||
${optionalString cfg.dap.enable ''
|
|
||||||
debugger = {
|
|
||||||
enabled = true,
|
|
||||||
},
|
|
||||||
''}
|
|
||||||
}
|
|
||||||
'';
|
|
||||||
})
|
|
||||||
]);
|
|
||||||
}
|
|
|
@ -1,6 +0,0 @@
|
||||||
{
|
|
||||||
imports = [
|
|
||||||
./dart.nix
|
|
||||||
./config.nix
|
|
||||||
];
|
|
||||||
}
|
|
|
@ -2,20 +2,19 @@
|
||||||
inherit (lib.nvim.languages) mkEnable;
|
inherit (lib.nvim.languages) mkEnable;
|
||||||
in {
|
in {
|
||||||
imports = [
|
imports = [
|
||||||
./bash
|
./bash.nix
|
||||||
./dart
|
./dart.nix
|
||||||
./elixir
|
|
||||||
./markdown
|
|
||||||
./tidal
|
|
||||||
|
|
||||||
./clang.nix
|
./clang.nix
|
||||||
./css.nix
|
./css.nix
|
||||||
|
./elixir.nix
|
||||||
./go.nix
|
./go.nix
|
||||||
./html.nix
|
./html.nix
|
||||||
./java.nix
|
./java.nix
|
||||||
./lua.nix
|
./lua.nix
|
||||||
|
./markdown.nix
|
||||||
./nim.nix
|
./nim.nix
|
||||||
./nix.nix
|
./nix.nix
|
||||||
|
./ocaml.nix
|
||||||
./php.nix
|
./php.nix
|
||||||
./python.nix
|
./python.nix
|
||||||
./rust.nix
|
./rust.nix
|
||||||
|
|
138
modules/plugins/languages/elixir.nix
Normal file
138
modules/plugins/languages/elixir.nix
Normal file
|
@ -0,0 +1,138 @@
|
||||||
|
{
|
||||||
|
config,
|
||||||
|
pkgs,
|
||||||
|
lib,
|
||||||
|
...
|
||||||
|
}: let
|
||||||
|
inherit (builtins) attrNames;
|
||||||
|
inherit (lib.options) mkEnableOption mkOption;
|
||||||
|
inherit (lib.modules) mkIf mkMerge;
|
||||||
|
inherit (lib.lists) isList;
|
||||||
|
inherit (lib.types) enum either listOf package str;
|
||||||
|
inherit (lib.nvim.types) mkGrammarOption;
|
||||||
|
inherit (lib.nvim.lua) expToLua;
|
||||||
|
inherit (lib.nvim.dag) entryAnywhere;
|
||||||
|
|
||||||
|
cfg = config.vim.languages.elixir;
|
||||||
|
|
||||||
|
defaultServer = "elixirls";
|
||||||
|
servers = {
|
||||||
|
elixirls = {
|
||||||
|
package = pkgs.elixir-ls;
|
||||||
|
lspConfig = ''
|
||||||
|
-- elixirls setup
|
||||||
|
lspconfig.elixirls.setup {
|
||||||
|
capabilities = capabilities,
|
||||||
|
on_attach = default_on_attach,
|
||||||
|
cmd = ${
|
||||||
|
if isList cfg.lsp.package
|
||||||
|
then expToLua cfg.lsp.package
|
||||||
|
else ''{"${cfg.lsp.package}/bin/elixir-ls"}''
|
||||||
|
}
|
||||||
|
}
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
defaultFormat = "mix";
|
||||||
|
formats = {
|
||||||
|
mix = {
|
||||||
|
package = pkgs.elixir;
|
||||||
|
nullConfig = ''
|
||||||
|
table.insert(
|
||||||
|
ls_sources,
|
||||||
|
null_ls.builtins.formatting.mix.with({
|
||||||
|
command = "${cfg.format.package}/bin/mix",
|
||||||
|
})
|
||||||
|
)
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
};
|
||||||
|
in {
|
||||||
|
options.vim.languages.elixir = {
|
||||||
|
enable = mkEnableOption "Elixir language support";
|
||||||
|
|
||||||
|
treesitter = {
|
||||||
|
enable = mkEnableOption "Elixir treesitter" // {default = config.vim.languages.enableTreesitter;};
|
||||||
|
package = mkGrammarOption pkgs "elixir";
|
||||||
|
};
|
||||||
|
|
||||||
|
lsp = {
|
||||||
|
enable = mkEnableOption "Elixir LSP support" // {default = config.vim.languages.enableLSP;};
|
||||||
|
|
||||||
|
server = mkOption {
|
||||||
|
description = "Elixir LSP server to use";
|
||||||
|
type = enum (attrNames servers);
|
||||||
|
default = defaultServer;
|
||||||
|
};
|
||||||
|
|
||||||
|
package = mkOption {
|
||||||
|
description = "Elixir LSP server package, or the command to run as a list of strings";
|
||||||
|
example = ''[lib.getExe pkgs.jdt-language-server " - data " " ~/.cache/jdtls/workspace "]'';
|
||||||
|
type = either package (listOf str);
|
||||||
|
default = servers.${cfg.lsp.server}.package;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
format = {
|
||||||
|
enable = mkEnableOption "Elixir formatting" // {default = config.vim.languages.enableFormat;};
|
||||||
|
|
||||||
|
type = mkOption {
|
||||||
|
description = "Elixir formatter to use";
|
||||||
|
type = enum (attrNames formats);
|
||||||
|
default = defaultFormat;
|
||||||
|
};
|
||||||
|
|
||||||
|
package = mkOption {
|
||||||
|
description = "Elixir formatter package";
|
||||||
|
type = package;
|
||||||
|
default = formats.${cfg.format.type}.package;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
elixir-tools = {
|
||||||
|
enable = mkEnableOption "Elixir tools";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
config = mkIf cfg.enable (mkMerge [
|
||||||
|
(mkIf cfg.treesitter.enable {
|
||||||
|
vim.treesitter.enable = true;
|
||||||
|
vim.treesitter.grammars = [cfg.treesitter.package];
|
||||||
|
})
|
||||||
|
|
||||||
|
(mkIf cfg.lsp.enable {
|
||||||
|
vim.lsp.lspconfig.enable = true;
|
||||||
|
vim.lsp.lspconfig.sources.elixir-lsp = servers.${cfg.lsp.server}.lspConfig;
|
||||||
|
})
|
||||||
|
|
||||||
|
(mkIf cfg.format.enable {
|
||||||
|
vim.lsp.null-ls.enable = true;
|
||||||
|
vim.lsp.null-ls.sources.elixir-format = formats.${cfg.format.type}.nullConfig;
|
||||||
|
})
|
||||||
|
|
||||||
|
(mkIf cfg.elixir-tools.enable {
|
||||||
|
vim.startPlugins = ["elixir-tools"];
|
||||||
|
vim.luaConfigRC.elixir-tools = entryAnywhere ''
|
||||||
|
local elixir-tools = require("elixir")
|
||||||
|
local elixirls = require("elixir-tools.elixirls")
|
||||||
|
|
||||||
|
-- disable imperative insstallations of various
|
||||||
|
-- elixir related tools installed by elixir-tools
|
||||||
|
elixir-tools.setup {
|
||||||
|
nextls = {
|
||||||
|
enable = false -- defaults to false
|
||||||
|
},
|
||||||
|
|
||||||
|
credo = {
|
||||||
|
enable = false -- defaults to true
|
||||||
|
},
|
||||||
|
|
||||||
|
elixirls = {
|
||||||
|
enable = false, -- defaults to true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
'';
|
||||||
|
})
|
||||||
|
]);
|
||||||
|
}
|
|
@ -1,67 +0,0 @@
|
||||||
{
|
|
||||||
config,
|
|
||||||
lib,
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}: let
|
|
||||||
inherit (lib.modules) mkIf;
|
|
||||||
inherit (lib.meta) getExe;
|
|
||||||
inherit (lib.nvim.dag) entryAnywhere;
|
|
||||||
|
|
||||||
cfg = config.vim.languages.elixir;
|
|
||||||
in {
|
|
||||||
config = mkIf (cfg.enable) {
|
|
||||||
vim.startPlugins = [
|
|
||||||
"elixir-tools"
|
|
||||||
];
|
|
||||||
|
|
||||||
vim.luaConfigRC.elixir-tools = entryAnywhere ''
|
|
||||||
local elixir = require("elixir")
|
|
||||||
local elixirls = require("elixir.elixirls")
|
|
||||||
|
|
||||||
elixir.setup {
|
|
||||||
elixirls = {
|
|
||||||
-- alternatively, point to an existing elixir-ls installation (optional)
|
|
||||||
-- not currently supported by elixirls, but can be a table if you wish to pass other args `{"path/to/elixirls", "--foo"}`
|
|
||||||
cmd = "${getExe pkgs.elixir-ls}",
|
|
||||||
|
|
||||||
-- default settings, use the `settings` function to override settings
|
|
||||||
settings = elixirls.settings {
|
|
||||||
dialyzerEnabled = true,
|
|
||||||
fetchDeps = false,
|
|
||||||
enableTestLenses = false,
|
|
||||||
suggestSpecs = false,
|
|
||||||
},
|
|
||||||
|
|
||||||
on_attach = function(client, bufnr)
|
|
||||||
local map_opts = { buffer = true, noremap = true}
|
|
||||||
|
|
||||||
-- run the codelens under the cursor
|
|
||||||
vim.keymap.set("n", "<space>r", vim.lsp.codelens.run, map_opts)
|
|
||||||
-- remove the pipe operator
|
|
||||||
vim.keymap.set("n", "<space>fp", ":ElixirFromPipe<cr>", map_opts)
|
|
||||||
-- add the pipe operator
|
|
||||||
vim.keymap.set("n", "<space>tp", ":ElixirToPipe<cr>", map_opts)
|
|
||||||
vim.keymap.set("v", "<space>em", ":ElixirExpandMacro<cr>", map_opts)
|
|
||||||
|
|
||||||
-- bindings for standard LSP functions.
|
|
||||||
vim.keymap.set("n", "<space>df", "<cmd>lua vim.lsp.buf.format()<cr>", map_opts)
|
|
||||||
vim.keymap.set("n", "<space>gd", "<cmd>lua vim.diagnostic.open_float()<cr>", map_opts)
|
|
||||||
vim.keymap.set("n", "<space>dt", "<cmd>lua vim.lsp.buf.definition()<cr>", map_opts)
|
|
||||||
vim.keymap.set("n", "<space>K", "<cmd>lua vim.lsp.buf.hover()<cr>", map_opts)
|
|
||||||
vim.keymap.set("n", "<space>gD","<cmd>lua vim.lsp.buf.implementation()<cr>", map_opts)
|
|
||||||
vim.keymap.set("n", "<space>1gD","<cmd>lua vim.lsp.buf.type_definition()<cr>", map_opts)
|
|
||||||
|
|
||||||
-- keybinds for fzf-lsp.nvim: https://github.com/gfanto/fzf-lsp.nvim
|
|
||||||
-- you could also use telescope.nvim: https://github.com/nvim-telescope/telescope.nvim
|
|
||||||
-- there are also core vim.lsp functions that put the same data in the loclist
|
|
||||||
vim.keymap.set("n", "<space>gr", ":References<cr>", map_opts)
|
|
||||||
vim.keymap.set("n", "<space>g0", ":DocumentSymbols<cr>", map_opts)
|
|
||||||
vim.keymap.set("n", "<space>gW", ":WorkspaceSymbols<cr>", map_opts)
|
|
||||||
vim.keymap.set("n", "<leader>d", ":Diagnostics<cr>", map_opts)
|
|
||||||
end
|
|
||||||
}
|
|
||||||
}
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -1,6 +0,0 @@
|
||||||
{
|
|
||||||
imports = [
|
|
||||||
./config.nix
|
|
||||||
./elixir-tools.nix
|
|
||||||
];
|
|
||||||
}
|
|
|
@ -1,7 +0,0 @@
|
||||||
{lib, ...}: let
|
|
||||||
inherit (lib.options) mkEnableOption;
|
|
||||||
in {
|
|
||||||
options.vim.languages.elixir = {
|
|
||||||
enable = mkEnableOption "Elixir language support";
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -4,7 +4,8 @@
|
||||||
lib,
|
lib,
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
inherit (builtins) attrNames;
|
inherit (builtins) attrNames concatLists;
|
||||||
|
inherit (lib.modules) mkIf mkMerge;
|
||||||
inherit (lib.options) mkEnableOption mkOption;
|
inherit (lib.options) mkEnableOption mkOption;
|
||||||
inherit (lib.lists) isList;
|
inherit (lib.lists) isList;
|
||||||
inherit (lib.types) bool enum either package listOf str;
|
inherit (lib.types) bool enum either package listOf str;
|
||||||
|
@ -29,15 +30,31 @@
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
defaultFormat = "denofmt";
|
||||||
|
formats = {
|
||||||
|
denofmt = {
|
||||||
|
package = pkgs.deno;
|
||||||
|
nullConfig = ''
|
||||||
|
table.insert(
|
||||||
|
ls_sources,
|
||||||
|
null_ls.builtins.formatting.deno_fmt.with({
|
||||||
|
filetypes = ${expToLua (concatLists [cfg.format.extraFiletypes ["markdown"]])},
|
||||||
|
command = "${cfg.format.package}/bin/deno",
|
||||||
|
})
|
||||||
|
)
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
};
|
||||||
in {
|
in {
|
||||||
options.vim.languages.markdown = {
|
options.vim.languages.markdown = {
|
||||||
enable = mkEnableOption "Markdown markup language support";
|
enable = mkEnableOption "Markdown markup language support";
|
||||||
|
|
||||||
treesitter = {
|
treesitter = {
|
||||||
enable = mkOption {
|
enable = mkOption {
|
||||||
description = "Enable Markdown treesitter";
|
|
||||||
type = bool;
|
type = bool;
|
||||||
default = config.vim.languages.enableTreesitter;
|
default = config.vim.languages.enableTreesitter;
|
||||||
|
description = "Enable Markdown treesitter";
|
||||||
};
|
};
|
||||||
mdPackage = mkGrammarOption pkgs "markdown";
|
mdPackage = mkGrammarOption pkgs "markdown";
|
||||||
mdInlinePackage = mkGrammarOption pkgs "markdown-inline";
|
mdInlinePackage = mkGrammarOption pkgs "markdown-inline";
|
||||||
|
@ -47,17 +64,56 @@ in {
|
||||||
enable = mkEnableOption "Enable Markdown LSP support" // {default = config.vim.languages.enableLSP;};
|
enable = mkEnableOption "Enable Markdown LSP support" // {default = config.vim.languages.enableLSP;};
|
||||||
|
|
||||||
server = mkOption {
|
server = mkOption {
|
||||||
description = "Markdown LSP server to use";
|
|
||||||
type = enum (attrNames servers);
|
type = enum (attrNames servers);
|
||||||
default = defaultServer;
|
default = defaultServer;
|
||||||
|
description = "Markdown LSP server to use";
|
||||||
};
|
};
|
||||||
|
|
||||||
package = mkOption {
|
package = mkOption {
|
||||||
description = "Markdown LSP server package, or the command to run as a list of strings";
|
|
||||||
example = ''[lib.getExe pkgs.jdt-language-server " - data " " ~/.cache/jdtls/workspace "]'';
|
|
||||||
type = either package (listOf str);
|
type = either package (listOf str);
|
||||||
default = servers.${cfg.lsp.server}.package;
|
default = servers.${cfg.lsp.server}.package;
|
||||||
|
example = ''[lib.getExe pkgs.jdt-language-server " - data " " ~/.cache/jdtls/workspace "]'';
|
||||||
|
description = "Markdown LSP server package, or the command to run as a list of strings";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
format = {
|
||||||
|
enable = mkEnableOption "Markdown formatting" // {default = config.vim.languages.enableFormat;};
|
||||||
|
|
||||||
|
type = mkOption {
|
||||||
|
type = enum (attrNames formats);
|
||||||
|
default = defaultFormat;
|
||||||
|
description = "Markdown formatter to use";
|
||||||
|
};
|
||||||
|
|
||||||
|
package = mkOption {
|
||||||
|
type = package;
|
||||||
|
default = formats.${cfg.format.type}.package;
|
||||||
|
description = "Markdown formatter package";
|
||||||
|
};
|
||||||
|
|
||||||
|
extraFiletypes = mkOption {
|
||||||
|
type = listOf str;
|
||||||
|
default = [];
|
||||||
|
description = "Extra filetypes to format with the Markdown formatter";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
config = mkIf cfg.enable (mkMerge [
|
||||||
|
(mkIf cfg.treesitter.enable {
|
||||||
|
vim.treesitter.enable = true;
|
||||||
|
vim.treesitter.grammars = [cfg.treesitter.mdPackage cfg.treesitter.mdInlinePackage];
|
||||||
|
})
|
||||||
|
|
||||||
|
(mkIf cfg.lsp.enable {
|
||||||
|
vim.lsp.lspconfig.enable = true;
|
||||||
|
vim.lsp.lspconfig.sources.markdown-lsp = servers.${cfg.lsp.server}.lspConfig;
|
||||||
|
})
|
||||||
|
|
||||||
|
(mkIf cfg.format.enable {
|
||||||
|
vim.lsp.null-ls.enable = true;
|
||||||
|
vim.lsp.null-ls.sources.markdown-format = formats.${cfg.format.type}.nullConfig;
|
||||||
|
})
|
||||||
|
]);
|
||||||
}
|
}
|
|
@ -1,40 +0,0 @@
|
||||||
{
|
|
||||||
pkgs,
|
|
||||||
config,
|
|
||||||
lib,
|
|
||||||
...
|
|
||||||
}: let
|
|
||||||
inherit (lib.nvim.lua) expToLua;
|
|
||||||
inherit (lib.modules) mkIf mkMerge;
|
|
||||||
inherit (lib.lists) isList;
|
|
||||||
|
|
||||||
cfg = config.vim.languages.markdown;
|
|
||||||
servers = {
|
|
||||||
marksman = {
|
|
||||||
package = pkgs.marksman;
|
|
||||||
lspConfig = ''
|
|
||||||
lspconfig.marksman.setup{
|
|
||||||
capabilities = capabilities;
|
|
||||||
on_attach = default_on_attach;
|
|
||||||
cmd = ${
|
|
||||||
if isList cfg.lsp.package
|
|
||||||
then expToLua cfg.lsp.package
|
|
||||||
else ''{"${cfg.lsp.package}/bin/marksman", "server"}''
|
|
||||||
},
|
|
||||||
}
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
};
|
|
||||||
in {
|
|
||||||
config = mkIf cfg.enable (mkMerge [
|
|
||||||
(mkIf cfg.treesitter.enable {
|
|
||||||
vim.treesitter.enable = true;
|
|
||||||
vim.treesitter.grammars = [cfg.treesitter.mdPackage cfg.treesitter.mdInlinePackage];
|
|
||||||
})
|
|
||||||
|
|
||||||
(mkIf cfg.lsp.enable {
|
|
||||||
vim.lsp.lspconfig.enable = true;
|
|
||||||
vim.lsp.lspconfig.sources.markdown-lsp = servers.${cfg.lsp.server}.lspConfig;
|
|
||||||
})
|
|
||||||
]);
|
|
||||||
}
|
|
|
@ -1,6 +0,0 @@
|
||||||
{...}: {
|
|
||||||
imports = [
|
|
||||||
./config.nix
|
|
||||||
./markdown.nix
|
|
||||||
];
|
|
||||||
}
|
|
105
modules/plugins/languages/ocaml.nix
Normal file
105
modules/plugins/languages/ocaml.nix
Normal file
|
@ -0,0 +1,105 @@
|
||||||
|
{
|
||||||
|
config,
|
||||||
|
pkgs,
|
||||||
|
lib,
|
||||||
|
...
|
||||||
|
}: let
|
||||||
|
inherit (builtins) attrNames;
|
||||||
|
inherit (lib.options) mkEnableOption mkOption;
|
||||||
|
inherit (lib.modules) mkIf mkMerge;
|
||||||
|
inherit (lib.meta) getExe;
|
||||||
|
inherit (lib.lists) isList;
|
||||||
|
inherit (lib.types) either enum listOf package str;
|
||||||
|
inherit (lib.nvim.types) mkGrammarOption;
|
||||||
|
inherit (lib.nvim.lua) expToLua;
|
||||||
|
|
||||||
|
cfg = config.vim.languages.ocaml;
|
||||||
|
|
||||||
|
defaultServer = "ocaml-lsp";
|
||||||
|
servers = {
|
||||||
|
ocaml-lsp = {
|
||||||
|
package = pkgs.ocamlPackages.ocaml-lsp;
|
||||||
|
lspConfig = ''
|
||||||
|
lspconfig.ocamllsp.setup {
|
||||||
|
capabilities = capabilities,
|
||||||
|
on_attach = default_on_attach,
|
||||||
|
cmd = ${
|
||||||
|
if isList cfg.lsp.package
|
||||||
|
then expToLua cfg.lsp.package
|
||||||
|
else ''{"${getExe cfg.lsp.package}"}''
|
||||||
|
};
|
||||||
|
}
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
defaultFormat = "ocamlformat";
|
||||||
|
formats = {
|
||||||
|
ocamlformat = {
|
||||||
|
package = pkgs.ocamlPackages.ocamlformat;
|
||||||
|
nullConfig = ''
|
||||||
|
table.insert(
|
||||||
|
ls_sources,
|
||||||
|
null_ls.builtins.formatting.ocamlformat.with({
|
||||||
|
command = "${cfg.format.package}/bin/ocamlformat",
|
||||||
|
})
|
||||||
|
)
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
};
|
||||||
|
in {
|
||||||
|
options.vim.languages.ocaml = {
|
||||||
|
enable = mkEnableOption "OCaml language support";
|
||||||
|
|
||||||
|
treesitter = {
|
||||||
|
enable = mkEnableOption "OCaml treesitter" // {default = config.vim.languages.enableTreesitter;};
|
||||||
|
package = mkGrammarOption pkgs "ocaml";
|
||||||
|
};
|
||||||
|
|
||||||
|
lsp = {
|
||||||
|
enable = mkEnableOption "OCaml LSP support (ocaml-lsp)" // {default = config.vim.languages.enableLSP;};
|
||||||
|
server = mkOption {
|
||||||
|
description = "OCaml LSP server to user";
|
||||||
|
type = enum (attrNames servers);
|
||||||
|
default = defaultServer;
|
||||||
|
};
|
||||||
|
package = mkOption {
|
||||||
|
description = "OCaml language server package, or the command to run as a list of strings";
|
||||||
|
type = either package (listOf str);
|
||||||
|
default = servers.${cfg.lsp.server}.package;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
format = {
|
||||||
|
enable = mkEnableOption "OCaml formatting support (ocamlformat)" // {default = config.vim.languages.enableFormat;};
|
||||||
|
type = mkOption {
|
||||||
|
description = "OCaml formatter to use";
|
||||||
|
type = enum (attrNames formats);
|
||||||
|
default = defaultFormat;
|
||||||
|
};
|
||||||
|
package = mkOption {
|
||||||
|
description = "OCaml formatter package";
|
||||||
|
type = package;
|
||||||
|
default = formats.${cfg.format.type}.package;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
config = mkIf cfg.enable (mkMerge [
|
||||||
|
(mkIf cfg.lsp.enable {
|
||||||
|
vim.lsp.lspconfig.enable = true;
|
||||||
|
vim.lsp.lspconfig.sources.ocaml-lsp = servers.${cfg.lsp.server}.lspConfig;
|
||||||
|
})
|
||||||
|
|
||||||
|
(mkIf cfg.treesitter.enable {
|
||||||
|
vim.treesitter.enable = true;
|
||||||
|
vim.treesitter.grammars = [cfg.treesitter.package];
|
||||||
|
})
|
||||||
|
|
||||||
|
(mkIf cfg.format.enable {
|
||||||
|
vim.lsp.null-ls.enable = true;
|
||||||
|
vim.lsp.null-ls.sources.ocamlformat = formats.${cfg.format.type}.nullConfig;
|
||||||
|
vim.extraPackages = [formats.${cfg.format.type}.package];
|
||||||
|
})
|
||||||
|
]);
|
||||||
|
}
|
|
@ -1,23 +0,0 @@
|
||||||
{
|
|
||||||
pkgs,
|
|
||||||
config,
|
|
||||||
lib,
|
|
||||||
...
|
|
||||||
}: let
|
|
||||||
inherit (lib.modules) mkIf;
|
|
||||||
|
|
||||||
cfg = config.vim.tidal;
|
|
||||||
in {
|
|
||||||
config = mkIf (cfg.enable) {
|
|
||||||
vim.startPlugins = [
|
|
||||||
# From tidalcycles flake
|
|
||||||
pkgs.vimPlugins.vim-tidal
|
|
||||||
];
|
|
||||||
|
|
||||||
vim.globals = {
|
|
||||||
"tidal_target" = "terminal";
|
|
||||||
"tidal_flash_duration" = 150;
|
|
||||||
"tidal_sc_enable" = cfg.openSC;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -1,6 +0,0 @@
|
||||||
{...}: {
|
|
||||||
imports = [
|
|
||||||
./tidal.nix
|
|
||||||
./config.nix
|
|
||||||
];
|
|
||||||
}
|
|
|
@ -1,24 +0,0 @@
|
||||||
{
|
|
||||||
config,
|
|
||||||
lib,
|
|
||||||
...
|
|
||||||
}: let
|
|
||||||
inherit (lib.options) mkEnableOption mkOption;
|
|
||||||
inherit (lib.types) int bool;
|
|
||||||
in {
|
|
||||||
options.vim.tidal = {
|
|
||||||
enable = mkEnableOption "tidalcycles tools and plugins";
|
|
||||||
|
|
||||||
flash = mkOption {
|
|
||||||
description = ''When sending a paragraph or a single line, vim-tidal will "flash" the selection for some milliseconds'';
|
|
||||||
type = int;
|
|
||||||
default = 150;
|
|
||||||
};
|
|
||||||
|
|
||||||
openSC = mkOption {
|
|
||||||
description = "Automatically run the supercollider CLI, sclang, alongside the Tidal GHCI terminal.";
|
|
||||||
type = bool;
|
|
||||||
default = true;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -16,7 +16,10 @@
|
||||||
|
|
||||||
mappingDefinitions = self.options.vim.lsp.mappings;
|
mappingDefinitions = self.options.vim.lsp.mappings;
|
||||||
mappings = addDescriptionsToMappings cfg.mappings mappingDefinitions;
|
mappings = addDescriptionsToMappings cfg.mappings mappingDefinitions;
|
||||||
mkBinding = binding: action: "vim.api.nvim_buf_set_keymap(bufnr, 'n', '${binding.value}', '<cmd>lua ${action}<CR>', {noremap=true, silent=true, desc='${binding.description}'})";
|
mkBinding = binding: action:
|
||||||
|
if binding.value != null
|
||||||
|
then "vim.api.nvim_buf_set_keymap(bufnr, 'n', '${binding.value}', '<cmd>lua ${action}<CR>', {noremap=true, silent=true, desc='${binding.description}'})"
|
||||||
|
else "";
|
||||||
in {
|
in {
|
||||||
config = mkIf cfg.enable {
|
config = mkIf cfg.enable {
|
||||||
vim = {
|
vim = {
|
||||||
|
|
|
@ -5,6 +5,7 @@
|
||||||
}: let
|
}: let
|
||||||
inherit (lib.modules) mkIf mkMerge;
|
inherit (lib.modules) mkIf mkMerge;
|
||||||
inherit (lib.attrsets) mapAttrs;
|
inherit (lib.attrsets) mapAttrs;
|
||||||
|
inherit (lib.trivial) boolToString;
|
||||||
inherit (lib.nvim.dag) entryAnywhere entryAfter entryBetween;
|
inherit (lib.nvim.dag) entryAnywhere entryAfter entryBetween;
|
||||||
|
|
||||||
cfg = config.vim.lsp;
|
cfg = config.vim.lsp;
|
||||||
|
@ -12,26 +13,36 @@ in {
|
||||||
config = mkIf cfg.null-ls.enable (mkMerge [
|
config = mkIf cfg.null-ls.enable (mkMerge [
|
||||||
{
|
{
|
||||||
vim = {
|
vim = {
|
||||||
|
startPlugins = [
|
||||||
|
"none-ls"
|
||||||
|
"plenary-nvim"
|
||||||
|
];
|
||||||
|
|
||||||
|
# null-ls implies LSP already being set up
|
||||||
|
# since it will hook into LSPs to receive information
|
||||||
lsp.enable = true;
|
lsp.enable = true;
|
||||||
startPlugins = ["none-ls"];
|
|
||||||
|
|
||||||
luaConfigRC.null_ls-setup = entryAnywhere ''
|
luaConfigRC = {
|
||||||
local null_ls = require("null-ls")
|
# early setup for null-ls
|
||||||
local null_helpers = require("null-ls.helpers")
|
null_ls-setup = entryAnywhere ''
|
||||||
local null_methods = require("null-ls.methods")
|
local null_ls = require("null-ls")
|
||||||
local ls_sources = {}
|
local null_helpers = require("null-ls.helpers")
|
||||||
'';
|
local null_methods = require("null-ls.methods")
|
||||||
|
local ls_sources = {}
|
||||||
|
'';
|
||||||
|
|
||||||
luaConfigRC.null_ls = entryAfter ["null_ls-setup" "lsp-setup"] ''
|
# null-ls setup
|
||||||
require('null-ls').setup({
|
null_ls = entryAfter ["null_ls-setup" "lsp-setup"] ''
|
||||||
debug = false,
|
require('null-ls').setup({
|
||||||
diagnostics_format = "[#{m}] #{s} (#{c})",
|
debug = ${boolToString cfg.null-ls.debug},
|
||||||
debounce = 250,
|
diagnostics_format = "${cfg.null-ls.diagnostics_format}",
|
||||||
default_timeout = 5000,
|
debounce = ${toString cfg.null-ls.debounce},
|
||||||
sources = ls_sources,
|
default_timeout = ${toString cfg.null-ls.default_timeout},
|
||||||
on_attach = default_on_attach
|
sources = ls_sources,
|
||||||
})
|
on_attach = default_on_attach
|
||||||
'';
|
})
|
||||||
|
'';
|
||||||
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
|
|
|
@ -1,10 +1,30 @@
|
||||||
{lib, ...}: let
|
{lib, ...}: let
|
||||||
inherit (lib.options) mkEnableOption mkOption;
|
inherit (lib.options) mkEnableOption mkOption;
|
||||||
inherit (lib.types) attrsOf str;
|
inherit (lib.types) attrsOf str int;
|
||||||
in {
|
in {
|
||||||
options.vim.lsp.null-ls = {
|
options.vim.lsp.null-ls = {
|
||||||
enable = mkEnableOption "null-ls, also enabled automatically";
|
enable = mkEnableOption "null-ls, also enabled automatically";
|
||||||
|
|
||||||
|
debug = mkEnableOption "debugging information for `null-ls";
|
||||||
|
|
||||||
|
diagnostics_format = mkOption {
|
||||||
|
type = str;
|
||||||
|
default = "[#{m}] #{s} (#{c})";
|
||||||
|
description = "Diagnostic output format for null-ls";
|
||||||
|
};
|
||||||
|
|
||||||
|
debounce = mkOption {
|
||||||
|
type = int;
|
||||||
|
default = 250;
|
||||||
|
description = "Default debounce";
|
||||||
|
};
|
||||||
|
|
||||||
|
default_timeout = mkOption {
|
||||||
|
type = int;
|
||||||
|
default = 5000;
|
||||||
|
description = "Default timeout value, in miliseconds";
|
||||||
|
};
|
||||||
|
|
||||||
sources = mkOption {
|
sources = mkOption {
|
||||||
description = "null-ls sources";
|
description = "null-ls sources";
|
||||||
type = attrsOf str;
|
type = attrsOf str;
|
||||||
|
|
|
@ -3,6 +3,7 @@
|
||||||
lib,
|
lib,
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
|
inherit (builtins) map;
|
||||||
inherit (lib.modules) mkIf mkMerge;
|
inherit (lib.modules) mkIf mkMerge;
|
||||||
inherit (lib.trivial) boolToString;
|
inherit (lib.trivial) boolToString;
|
||||||
inherit (lib.nvim.dag) entryAnywhere;
|
inherit (lib.nvim.dag) entryAnywhere;
|
||||||
|
@ -31,44 +32,46 @@ in {
|
||||||
};
|
};
|
||||||
})
|
})
|
||||||
(mkIf cfg.enable {
|
(mkIf cfg.enable {
|
||||||
vim.startPlugins = [
|
vim = {
|
||||||
"lualine"
|
startPlugins = ["lualine"];
|
||||||
];
|
|
||||||
|
|
||||||
vim.luaConfigRC.lualine = entryAnywhere ''
|
luaConfigRC.lualine = entryAnywhere ''
|
||||||
local lualine = require('lualine')
|
local lualine = require('lualine')
|
||||||
lualine.setup ${toLuaObject cfg.setupOpts}
|
lualine.setup ${toLuaObject cfg.setupOpts}
|
||||||
'';
|
'';
|
||||||
|
|
||||||
# this is for backwards-compatibility
|
# this is for backwards-compatibility
|
||||||
vim.statusline.lualine.setupOpts = {
|
statusline.lualine.setupOpts = {
|
||||||
options = {
|
options = {
|
||||||
icons_enabled = cfg.icons.enable;
|
icons_enabled = cfg.icons.enable;
|
||||||
theme = cfg.theme;
|
theme = cfg.theme;
|
||||||
component_separators = [cfg.componentSeparator.left cfg.componentSeparator.right];
|
component_separators = [cfg.componentSeparator.left cfg.componentSeparator.right];
|
||||||
section_separators = [cfg.sectionSeparator.left cfg.sectionSeparator.right];
|
section_separators = [cfg.sectionSeparator.left cfg.sectionSeparator.right];
|
||||||
globalstatus = cfg.globalStatus;
|
globalstatus = cfg.globalStatus;
|
||||||
refresh = cfg.refresh;
|
refresh = cfg.refresh;
|
||||||
};
|
};
|
||||||
|
|
||||||
sections = {
|
sections = {
|
||||||
lualine_a = builtins.map mkLuaInline (cfg.activeSection.a ++ cfg.extraActiveSection.a);
|
lualine_a = map mkLuaInline (cfg.activeSection.a ++ cfg.extraActiveSection.a);
|
||||||
lualine_b = builtins.map mkLuaInline (cfg.activeSection.b ++ cfg.extraActiveSection.b);
|
lualine_b = map mkLuaInline (cfg.activeSection.b ++ cfg.extraActiveSection.b);
|
||||||
lualine_c = builtins.map mkLuaInline (cfg.activeSection.c ++ cfg.extraActiveSection.c);
|
lualine_c = map mkLuaInline (cfg.activeSection.c ++ cfg.extraActiveSection.c);
|
||||||
lualine_x = builtins.map mkLuaInline (cfg.activeSection.x ++ cfg.extraActiveSection.x);
|
lualine_x = map mkLuaInline (cfg.activeSection.x ++ cfg.extraActiveSection.x);
|
||||||
lualine_y = builtins.map mkLuaInline (cfg.activeSection.y ++ cfg.extraActiveSection.y);
|
lualine_y = map mkLuaInline (cfg.activeSection.y ++ cfg.extraActiveSection.y);
|
||||||
lualine_z = builtins.map mkLuaInline (cfg.activeSection.z ++ cfg.extraActiveSection.z);
|
lualine_z = map mkLuaInline (cfg.activeSection.z ++ cfg.extraActiveSection.z);
|
||||||
|
};
|
||||||
|
|
||||||
|
inactive_sections = {
|
||||||
|
lualine_a = map mkLuaInline (cfg.inactiveSection.a ++ cfg.extraInactiveSection.a);
|
||||||
|
lualine_b = map mkLuaInline (cfg.inactiveSection.b ++ cfg.extraInactiveSection.b);
|
||||||
|
lualine_c = map mkLuaInline (cfg.inactiveSection.c ++ cfg.extraInactiveSection.c);
|
||||||
|
lualine_x = map mkLuaInline (cfg.inactiveSection.x ++ cfg.extraInactiveSection.x);
|
||||||
|
lualine_y = map mkLuaInline (cfg.inactiveSection.y ++ cfg.extraInactiveSection.y);
|
||||||
|
lualine_z = map mkLuaInline (cfg.inactiveSection.z ++ cfg.extraInactiveSection.z);
|
||||||
|
};
|
||||||
|
|
||||||
|
# probably don't need this?
|
||||||
|
tabline = [];
|
||||||
};
|
};
|
||||||
inactive_sections = {
|
|
||||||
lualine_a = builtins.map mkLuaInline (cfg.inactiveSection.a ++ cfg.extraInactiveSection.a);
|
|
||||||
lualine_b = builtins.map mkLuaInline (cfg.inactiveSection.b ++ cfg.extraInactiveSection.b);
|
|
||||||
lualine_c = builtins.map mkLuaInline (cfg.inactiveSection.c ++ cfg.extraInactiveSection.c);
|
|
||||||
lualine_x = builtins.map mkLuaInline (cfg.inactiveSection.x ++ cfg.extraInactiveSection.x);
|
|
||||||
lualine_y = builtins.map mkLuaInline (cfg.inactiveSection.y ++ cfg.extraInactiveSection.y);
|
|
||||||
lualine_z = builtins.map mkLuaInline (cfg.inactiveSection.z ++ cfg.extraInactiveSection.z);
|
|
||||||
};
|
|
||||||
# probably don't need this?
|
|
||||||
tabline = [];
|
|
||||||
};
|
};
|
||||||
})
|
})
|
||||||
];
|
];
|
||||||
|
|
|
@ -10,19 +10,45 @@
|
||||||
inherit (lib.nvim.types) mkPluginSetupOption;
|
inherit (lib.nvim.types) mkPluginSetupOption;
|
||||||
|
|
||||||
supported_themes = import ./supported_themes.nix;
|
supported_themes = import ./supported_themes.nix;
|
||||||
colorPuccin =
|
builtin_themes = [
|
||||||
if config.vim.statusline.lualine.theme == "catppuccin"
|
"auto"
|
||||||
then "#181825"
|
"16color"
|
||||||
else "none";
|
"gruvbox"
|
||||||
|
"ayu_dark"
|
||||||
|
"ayu_light"
|
||||||
|
"ayu_mirage"
|
||||||
|
"codedark"
|
||||||
|
"dracula"
|
||||||
|
"everforest"
|
||||||
|
"gruvbox"
|
||||||
|
"gruvbox_light"
|
||||||
|
"gruvbox_material"
|
||||||
|
"horizon"
|
||||||
|
"iceberg_dark"
|
||||||
|
"iceberg_light"
|
||||||
|
"jellybeans"
|
||||||
|
"material"
|
||||||
|
"modus_vivendi"
|
||||||
|
"molokai"
|
||||||
|
"nightfly"
|
||||||
|
"nord"
|
||||||
|
"oceanicnext"
|
||||||
|
"onelight"
|
||||||
|
"palenight"
|
||||||
|
"papercolor_dark"
|
||||||
|
"papercolor_light"
|
||||||
|
"powerline"
|
||||||
|
"seoul256"
|
||||||
|
"solarized_dark"
|
||||||
|
"tomorrow"
|
||||||
|
"wombat"
|
||||||
|
];
|
||||||
in {
|
in {
|
||||||
options.vim.statusline.lualine = {
|
options.vim.statusline.lualine = {
|
||||||
|
enable = mkEnableOption "lualine statusline plugin";
|
||||||
setupOpts = mkPluginSetupOption "Lualine" {};
|
setupOpts = mkPluginSetupOption "Lualine" {};
|
||||||
|
|
||||||
enable = mkEnableOption "lualine statusline plugin";
|
icons.enable = mkEnableOption "icons for lualine" // {default = true;};
|
||||||
|
|
||||||
icons = {
|
|
||||||
enable = mkEnableOption "icons for lualine" // {default = true;};
|
|
||||||
};
|
|
||||||
|
|
||||||
refresh = {
|
refresh = {
|
||||||
statusline = mkOption {
|
statusline = mkOption {
|
||||||
|
@ -73,47 +99,15 @@ in {
|
||||||
|
|
||||||
theme = let
|
theme = let
|
||||||
themeSupported = elem config.vim.theme.name supported_themes;
|
themeSupported = elem config.vim.theme.name supported_themes;
|
||||||
|
themesConcatted = builtin_themes ++ optional themeSupported config.vim.theme.name;
|
||||||
in
|
in
|
||||||
mkOption {
|
mkOption {
|
||||||
description = "Theme for lualine";
|
type = enum themesConcatted;
|
||||||
type = enum ([
|
|
||||||
"auto"
|
|
||||||
"16color"
|
|
||||||
"gruvbox"
|
|
||||||
"ayu_dark"
|
|
||||||
"ayu_light"
|
|
||||||
"ayu_mirage"
|
|
||||||
"codedark"
|
|
||||||
"dracula"
|
|
||||||
"everforest"
|
|
||||||
"gruvbox"
|
|
||||||
"gruvbox_light"
|
|
||||||
"gruvbox_material"
|
|
||||||
"horizon"
|
|
||||||
"iceberg_dark"
|
|
||||||
"iceberg_light"
|
|
||||||
"jellybeans"
|
|
||||||
"material"
|
|
||||||
"modus_vivendi"
|
|
||||||
"molokai"
|
|
||||||
"nightfly"
|
|
||||||
"nord"
|
|
||||||
"oceanicnext"
|
|
||||||
"onelight"
|
|
||||||
"palenight"
|
|
||||||
"papercolor_dark"
|
|
||||||
"papercolor_light"
|
|
||||||
"powerline"
|
|
||||||
"seoul256"
|
|
||||||
"solarized_dark"
|
|
||||||
"tomorrow"
|
|
||||||
"wombat"
|
|
||||||
]
|
|
||||||
++ optional themeSupported config.vim.theme.name);
|
|
||||||
default = "auto";
|
default = "auto";
|
||||||
# TODO: xml generation error if the closing '' is on a new line.
|
# TODO: xml generation error if the closing '' is on a new line.
|
||||||
# issue: https://gitlab.com/rycee/nmd/-/issues/10
|
# issue: https://gitlab.com/rycee/nmd/-/issues/10
|
||||||
defaultText = ''`config.vim.theme.name` if theme supports lualine else "auto"'';
|
defaultText = ''`config.vim.theme.name` if theme supports lualine else "auto"'';
|
||||||
|
description = "Theme for lualine";
|
||||||
};
|
};
|
||||||
|
|
||||||
sectionSeparator = {
|
sectionSeparator = {
|
||||||
|
@ -171,15 +165,14 @@ in {
|
||||||
"filetype",
|
"filetype",
|
||||||
colored = true,
|
colored = true,
|
||||||
icon_only = true,
|
icon_only = true,
|
||||||
icon = { align = 'left' },
|
icon = { align = 'left' }
|
||||||
color = {bg='${colorPuccin}', fg='lavender'},
|
|
||||||
}
|
}
|
||||||
''
|
''
|
||||||
''
|
''
|
||||||
{
|
{
|
||||||
"filename",
|
"filename",
|
||||||
color = {bg='${colorPuccin}'},
|
symbols = {modified = ' ', readonly = ' '},
|
||||||
symbols = {modified = '', readonly = ''},
|
separator = {right = ''}
|
||||||
}
|
}
|
||||||
''
|
''
|
||||||
];
|
];
|
||||||
|
@ -200,13 +193,7 @@ in {
|
||||||
removed = 'DiffDelete', -- Changes the diff's removed color you
|
removed = 'DiffDelete', -- Changes the diff's removed color you
|
||||||
},
|
},
|
||||||
symbols = {added = '+', modified = '~', removed = '-'}, -- Changes the diff symbols
|
symbols = {added = '+', modified = '~', removed = '-'}, -- Changes the diff symbols
|
||||||
color = {
|
separator = {right = ''}
|
||||||
bg='${colorPuccin}',
|
|
||||||
fg='lavender'
|
|
||||||
},
|
|
||||||
separator = {
|
|
||||||
right = ''
|
|
||||||
},
|
|
||||||
}
|
}
|
||||||
''
|
''
|
||||||
];
|
];
|
||||||
|
@ -251,18 +238,17 @@ in {
|
||||||
return msg
|
return msg
|
||||||
end,
|
end,
|
||||||
icon = ' ',
|
icon = ' ',
|
||||||
color = {bg='${colorPuccin}', fg='lavender'},
|
separator = {left = ''},
|
||||||
separator = {
|
|
||||||
left = '',
|
|
||||||
},
|
|
||||||
}
|
}
|
||||||
''
|
''
|
||||||
''
|
''
|
||||||
{
|
{
|
||||||
"diagnostics",
|
"diagnostics",
|
||||||
sources = {'nvim_lsp', 'nvim_diagnostic', 'coc'},
|
sources = {'nvim_lsp', 'nvim_diagnostic', 'nvim_diagnostic', 'vim_lsp', 'coc'},
|
||||||
symbols = {error = ' ', warn = ' ', info = ' ', hint = ' '},
|
symbols = {error = ' ', warn = ' ', info = ' ', hint = ' '},
|
||||||
color = {bg='${colorPuccin}', fg='lavender'},
|
colored = true,
|
||||||
|
update_in_insert = false,
|
||||||
|
always_visible = false,
|
||||||
diagnostics_color = {
|
diagnostics_color = {
|
||||||
color_error = { fg = 'red' },
|
color_error = { fg = 'red' },
|
||||||
color_warn = { fg = 'yellow' },
|
color_warn = { fg = 'yellow' },
|
||||||
|
@ -282,14 +268,14 @@ in {
|
||||||
'searchcount',
|
'searchcount',
|
||||||
maxcount = 999,
|
maxcount = 999,
|
||||||
timeout = 120,
|
timeout = 120,
|
||||||
color = {bg='${colorPuccin}', fg='lavender'}
|
separator = {left = ''}
|
||||||
}
|
}
|
||||||
''
|
''
|
||||||
''
|
''
|
||||||
{
|
{
|
||||||
"branch",
|
"branch",
|
||||||
icon = ' •',
|
icon = ' •',
|
||||||
color = {bg='${colorPuccin}', fg='lavender'},
|
separator = {left = ''}
|
||||||
}
|
}
|
||||||
''
|
''
|
||||||
];
|
];
|
||||||
|
@ -302,15 +288,11 @@ in {
|
||||||
''
|
''
|
||||||
{
|
{
|
||||||
"progress",
|
"progress",
|
||||||
separator = {
|
separator = {left = ''}
|
||||||
left = '',
|
|
||||||
},
|
|
||||||
}
|
}
|
||||||
''
|
''
|
||||||
''
|
''
|
||||||
{
|
{"location"}
|
||||||
"location",
|
|
||||||
}
|
|
||||||
''
|
''
|
||||||
''
|
''
|
||||||
{
|
{
|
||||||
|
@ -320,38 +302,44 @@ in {
|
||||||
unix = '', -- e712
|
unix = '', -- e712
|
||||||
dos = '', -- e70f
|
dos = '', -- e70f
|
||||||
mac = '', -- e711
|
mac = '', -- e711
|
||||||
},
|
}
|
||||||
}
|
}
|
||||||
''
|
''
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
extraActiveSection = {
|
extraActiveSection = {
|
||||||
a = mkOption {
|
a = mkOption {
|
||||||
type = listOf str;
|
type = listOf str;
|
||||||
description = "Extra entries for activeSection.a";
|
description = "Extra entries for activeSection.a";
|
||||||
default = [];
|
default = [];
|
||||||
};
|
};
|
||||||
|
|
||||||
b = mkOption {
|
b = mkOption {
|
||||||
type = listOf str;
|
type = listOf str;
|
||||||
description = "Extra entries for activeSection.b";
|
description = "Extra entries for activeSection.b";
|
||||||
default = [];
|
default = [];
|
||||||
};
|
};
|
||||||
|
|
||||||
c = mkOption {
|
c = mkOption {
|
||||||
type = listOf str;
|
type = listOf str;
|
||||||
description = "Extra entries for activeSection.c";
|
description = "Extra entries for activeSection.c";
|
||||||
default = [];
|
default = [];
|
||||||
};
|
};
|
||||||
|
|
||||||
x = mkOption {
|
x = mkOption {
|
||||||
type = listOf str;
|
type = listOf str;
|
||||||
description = "Extra entries for activeSection.x";
|
description = "Extra entries for activeSection.x";
|
||||||
default = [];
|
default = [];
|
||||||
};
|
};
|
||||||
|
|
||||||
y = mkOption {
|
y = mkOption {
|
||||||
type = listOf str;
|
type = listOf str;
|
||||||
description = "Extra entries for activeSection.y";
|
description = "Extra entries for activeSection.y";
|
||||||
default = [];
|
default = [];
|
||||||
};
|
};
|
||||||
|
|
||||||
z = mkOption {
|
z = mkOption {
|
||||||
type = listOf str;
|
type = listOf str;
|
||||||
description = "Extra entries for activeSection.z";
|
description = "Extra entries for activeSection.z";
|
||||||
|
@ -402,26 +390,31 @@ in {
|
||||||
description = "Extra entries for inactiveSection.a";
|
description = "Extra entries for inactiveSection.a";
|
||||||
default = [];
|
default = [];
|
||||||
};
|
};
|
||||||
|
|
||||||
b = mkOption {
|
b = mkOption {
|
||||||
type = listOf str;
|
type = listOf str;
|
||||||
description = "Extra entries for inactiveSection.b";
|
description = "Extra entries for inactiveSection.b";
|
||||||
default = [];
|
default = [];
|
||||||
};
|
};
|
||||||
|
|
||||||
c = mkOption {
|
c = mkOption {
|
||||||
type = listOf str;
|
type = listOf str;
|
||||||
description = "Extra entries for inactiveSection.c";
|
description = "Extra entries for inactiveSection.c";
|
||||||
default = [];
|
default = [];
|
||||||
};
|
};
|
||||||
|
|
||||||
x = mkOption {
|
x = mkOption {
|
||||||
type = listOf str;
|
type = listOf str;
|
||||||
description = "Extra entries for inactiveSection.x";
|
description = "Extra entries for inactiveSection.x";
|
||||||
default = [];
|
default = [];
|
||||||
};
|
};
|
||||||
|
|
||||||
y = mkOption {
|
y = mkOption {
|
||||||
type = listOf str;
|
type = listOf str;
|
||||||
description = "Extra entries for inactiveSection.y";
|
description = "Extra entries for inactiveSection.y";
|
||||||
default = [];
|
default = [];
|
||||||
};
|
};
|
||||||
|
|
||||||
z = mkOption {
|
z = mkOption {
|
||||||
type = listOf str;
|
type = listOf str;
|
||||||
description = "Extra entries for inactiveSection.z";
|
description = "Extra entries for inactiveSection.z";
|
||||||
|
|
|
@ -6,101 +6,30 @@
|
||||||
inherit (lib.modules) mkIf mkMerge;
|
inherit (lib.modules) mkIf mkMerge;
|
||||||
inherit (lib.nvim.binds) mkLuaBinding mkBinding pushDownDefault;
|
inherit (lib.nvim.binds) mkLuaBinding mkBinding pushDownDefault;
|
||||||
inherit (lib.nvim.dag) entryAnywhere;
|
inherit (lib.nvim.dag) entryAnywhere;
|
||||||
|
inherit (lib.nvim.lua) toLuaObject;
|
||||||
|
|
||||||
cfg = config.vim.tabline.nvimBufferline;
|
cfg = config.vim.tabline.nvimBufferline;
|
||||||
|
|
||||||
self = import ./nvim-bufferline.nix {inherit lib;};
|
self = import ./nvim-bufferline.nix {inherit lib;};
|
||||||
inherit (self.options.vim.tabline.nvimBufferline) mappings;
|
inherit (self.options.vim.tabline.nvimBufferline) mappings;
|
||||||
in {
|
in {
|
||||||
config = mkIf cfg.enable (
|
config = mkIf cfg.enable {
|
||||||
let
|
vim = {
|
||||||
mouse = {
|
startPlugins = [
|
||||||
right = "'vertical sbuffer %d'";
|
(assert config.vim.visuals.nvimWebDevicons.enable; "nvim-bufferline-lua")
|
||||||
close = ''
|
"bufdelete-nvim"
|
||||||
function(bufnum)
|
];
|
||||||
require("bufdelete").bufdelete(bufnum, false)
|
|
||||||
end
|
binds.whichKey.register = pushDownDefault {
|
||||||
'';
|
"<leader>b" = "+Buffer";
|
||||||
|
"<leader>bm" = "BufferLineMove";
|
||||||
|
"<leader>bs" = "BufferLineSort";
|
||||||
|
"<leader>bsi" = "BufferLineSortById";
|
||||||
};
|
};
|
||||||
in {
|
|
||||||
vim = {
|
|
||||||
startPlugins = [
|
|
||||||
(assert config.vim.visuals.nvimWebDevicons.enable; "nvim-bufferline-lua")
|
|
||||||
"bufdelete-nvim"
|
|
||||||
];
|
|
||||||
|
|
||||||
maps.normal = mkMerge [
|
luaConfigRC.nvimBufferline = entryAnywhere ''
|
||||||
(mkLuaBinding cfg.mappings.closeCurrent "require(\"bufdelete\").bufdelete" mappings.closeCurrent.description)
|
require("bufferline").setup({options = ${toLuaObject cfg.setupOpts}})
|
||||||
(mkBinding cfg.mappings.cycleNext ":BufferLineCycleNext<CR>" mappings.cycleNext.description)
|
'';
|
||||||
(mkBinding cfg.mappings.cycleNext ":BufferLineCycleNext<CR>" mappings.cycleNext.description)
|
};
|
||||||
(mkBinding cfg.mappings.cyclePrevious ":BufferLineCyclePrev<CR>" mappings.cyclePrevious.description)
|
};
|
||||||
(mkBinding cfg.mappings.pick ":BufferLinePick<CR>" mappings.pick.description)
|
|
||||||
(mkBinding cfg.mappings.sortByExtension ":BufferLineSortByExtension<CR>" mappings.sortByExtension.description)
|
|
||||||
(mkBinding cfg.mappings.sortByDirectory ":BufferLineSortByDirectory<CR>" mappings.sortByDirectory.description)
|
|
||||||
(mkLuaBinding cfg.mappings.sortById "function() require(\"bufferline\").sort_buffers_by(function (buf_a, buf_b) return buf_a.id < buf_b.id end) end" mappings.sortById.description)
|
|
||||||
(mkBinding cfg.mappings.moveNext ":BufferLineMoveNext<CR>" mappings.moveNext.description)
|
|
||||||
(mkBinding cfg.mappings.movePrevious ":BufferLineMovePrev<CR>" mappings.movePrevious.description)
|
|
||||||
];
|
|
||||||
|
|
||||||
binds.whichKey.register = pushDownDefault {
|
|
||||||
"<leader>b" = "+Buffer";
|
|
||||||
"<leader>bm" = "BufferLineMove";
|
|
||||||
"<leader>bs" = "BufferLineSort";
|
|
||||||
"<leader>bsi" = "BufferLineSortById";
|
|
||||||
};
|
|
||||||
|
|
||||||
luaConfigRC.nvimBufferline = entryAnywhere ''
|
|
||||||
require("bufferline").setup{
|
|
||||||
options = {
|
|
||||||
mode = "buffers",
|
|
||||||
numbers = "both",
|
|
||||||
close_command = ${mouse.close},
|
|
||||||
right_mouse_command = ${mouse.right},
|
|
||||||
indicator = {
|
|
||||||
style = 'icon',
|
|
||||||
indicator_icon = '▎',
|
|
||||||
},
|
|
||||||
buffer_close_icon = '',
|
|
||||||
modified_icon = '●',
|
|
||||||
close_icon = '',
|
|
||||||
left_trunc_marker = '',
|
|
||||||
right_trunc_marker = '',
|
|
||||||
max_name_length = 18,
|
|
||||||
max_prefix_length = 15,
|
|
||||||
tab_size = 18,
|
|
||||||
show_buffer_icons = true,
|
|
||||||
show_buffer_close_icons = true,
|
|
||||||
show_close_icon = true,
|
|
||||||
show_tab_indicators = true,
|
|
||||||
persist_buffer_sort = true,
|
|
||||||
--separator_style = "thin",
|
|
||||||
separator_style = { " ", " " },
|
|
||||||
enforce_regular_tabs = true,
|
|
||||||
always_show_bufferline = true,
|
|
||||||
offsets = {
|
|
||||||
{filetype = "NvimTree", text = "File Explorer", text_align = "center"}
|
|
||||||
},
|
|
||||||
sort_by = 'extension',
|
|
||||||
diagnostics = "nvim_lsp", -- TODO: use coc if it's enabled
|
|
||||||
diagnostics_update_in_insert = true,
|
|
||||||
diagnostics_indicator = function(count, level, diagnostics_dict, context)
|
|
||||||
local s = ""
|
|
||||||
for e, n in pairs(diagnostics_dict) do
|
|
||||||
local sym = e == "error" and ""
|
|
||||||
or (e == "warning" and "" or "" )
|
|
||||||
if(sym ~= "") then
|
|
||||||
s = s .. " " .. n .. sym
|
|
||||||
end
|
|
||||||
end
|
|
||||||
return s
|
|
||||||
end,
|
|
||||||
numbers = function(opts)
|
|
||||||
return string.format('%s·%s', opts.raise(opts.id), opts.lower(opts.ordinal))
|
|
||||||
end,
|
|
||||||
}
|
|
||||||
}
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
}
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,8 @@
|
||||||
{lib, ...}: let
|
{lib, ...}: let
|
||||||
inherit (lib.options) mkEnableOption;
|
inherit (lib.options) mkOption mkEnableOption literalExpression;
|
||||||
|
inherit (lib.types) enum bool either nullOr str int listOf;
|
||||||
inherit (lib.nvim.binds) mkMappingOption;
|
inherit (lib.nvim.binds) mkMappingOption;
|
||||||
|
inherit (lib.nvim.types) mkPluginSetupOption luaInline;
|
||||||
in {
|
in {
|
||||||
options.vim.tabline.nvimBufferline = {
|
options.vim.tabline.nvimBufferline = {
|
||||||
enable = mkEnableOption "neovim bufferline";
|
enable = mkEnableOption "neovim bufferline";
|
||||||
|
@ -16,5 +18,319 @@ in {
|
||||||
moveNext = mkMappingOption "Move next buffer" "<leader>bmn";
|
moveNext = mkMappingOption "Move next buffer" "<leader>bmn";
|
||||||
movePrevious = mkMappingOption "Move previous buffer" "<leader>bmp";
|
movePrevious = mkMappingOption "Move previous buffer" "<leader>bmp";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
setupOpts = mkPluginSetupOption "Bufferline-nvim" {
|
||||||
|
mode = mkOption {
|
||||||
|
type = enum ["tabs" "buffers"];
|
||||||
|
default = "tabs";
|
||||||
|
description = "Mode to use for bufferline";
|
||||||
|
};
|
||||||
|
|
||||||
|
themable = mkOption {
|
||||||
|
type = bool;
|
||||||
|
default = true;
|
||||||
|
description = ''
|
||||||
|
Whether or not highlight groups to be overriden.
|
||||||
|
|
||||||
|
While false, bufferline.nvim sets highlights as default
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
|
numbers = mkOption {
|
||||||
|
type = either (enum ["none" "ordinal" "buffer_id" "both"]) luaInline;
|
||||||
|
default = lib.generators.mkLuaInline ''
|
||||||
|
function(opts)
|
||||||
|
return string.format('%s·%s', opts.raise(opts.id), opts.lower(opts.ordinal))
|
||||||
|
end
|
||||||
|
'';
|
||||||
|
description = "Whether or not to show buffer numbers";
|
||||||
|
};
|
||||||
|
|
||||||
|
close_command = mkOption {
|
||||||
|
type = either str luaInline;
|
||||||
|
default = lib.generators.mkLuaInline ''
|
||||||
|
function(bufnum)
|
||||||
|
require("bufdelete").bufdelete(bufnum, false)
|
||||||
|
end
|
||||||
|
'';
|
||||||
|
description = "Command to run when closing a buffer";
|
||||||
|
};
|
||||||
|
|
||||||
|
right_mouse_command = mkOption {
|
||||||
|
type = nullOr (either str luaInline);
|
||||||
|
default = "vertical sbuffer %d";
|
||||||
|
description = "Command to run when right clicking a buffer";
|
||||||
|
};
|
||||||
|
|
||||||
|
middle_mouse_command = mkOption {
|
||||||
|
type = nullOr (either str luaInline);
|
||||||
|
default = null;
|
||||||
|
description = "Command to run when middle clicking a buffer";
|
||||||
|
};
|
||||||
|
|
||||||
|
indicator = {
|
||||||
|
icon = mkOption {
|
||||||
|
type = nullOr str;
|
||||||
|
default = null;
|
||||||
|
description = ''
|
||||||
|
The indicatotor icon to use for current buffer.
|
||||||
|
|
||||||
|
::: {.warning}
|
||||||
|
This **must** be ommitted while style is not `icon`
|
||||||
|
:::
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
|
style = mkOption {
|
||||||
|
type = enum ["icon" "underline" "none"];
|
||||||
|
default = "underline";
|
||||||
|
description = "Style for indicator";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
buffer_close_icon = mkOption {
|
||||||
|
type = str;
|
||||||
|
default = " ";
|
||||||
|
description = "Icon for close button";
|
||||||
|
};
|
||||||
|
|
||||||
|
modified_icon = mkOption {
|
||||||
|
type = str;
|
||||||
|
default = "● ";
|
||||||
|
description = "Icon for modified buffer";
|
||||||
|
};
|
||||||
|
|
||||||
|
close_icon = mkOption {
|
||||||
|
type = str;
|
||||||
|
default = " ";
|
||||||
|
description = "Icon for close button";
|
||||||
|
};
|
||||||
|
|
||||||
|
left_trunc_marker = mkOption {
|
||||||
|
type = str;
|
||||||
|
default = "";
|
||||||
|
description = "Icon for left truncation";
|
||||||
|
};
|
||||||
|
|
||||||
|
right_trunc_marker = mkOption {
|
||||||
|
type = str;
|
||||||
|
default = "";
|
||||||
|
description = "Icon for right truncation";
|
||||||
|
};
|
||||||
|
|
||||||
|
name_formatter = mkOption {
|
||||||
|
type = nullOr luaInline;
|
||||||
|
default = null;
|
||||||
|
description = ''
|
||||||
|
`name_formatter` can be used to change the buffer's label in the
|
||||||
|
bufferline.
|
||||||
|
|
||||||
|
::: {.note}
|
||||||
|
Some names can/will break the bufferline so use this at your
|
||||||
|
discretion knowing that it has some limitations that will
|
||||||
|
**NOT** be fixed.
|
||||||
|
:::
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
|
max_name_length = mkOption {
|
||||||
|
type = int;
|
||||||
|
default = 18;
|
||||||
|
description = "Max name length";
|
||||||
|
};
|
||||||
|
|
||||||
|
max_prefix_length = mkOption {
|
||||||
|
type = int;
|
||||||
|
default = 15;
|
||||||
|
description = "Length of prefix used when a buffer is de-duplicated";
|
||||||
|
};
|
||||||
|
|
||||||
|
truncate_names = mkOption {
|
||||||
|
type = bool;
|
||||||
|
default = true;
|
||||||
|
description = "Truncate names";
|
||||||
|
};
|
||||||
|
|
||||||
|
diagnostics = mkOption {
|
||||||
|
type = enum [false "nvim_lsp" "coc"];
|
||||||
|
default = "nvim_lsp";
|
||||||
|
description = "Diagnostics provider to be used in buffer LSP indicators";
|
||||||
|
};
|
||||||
|
|
||||||
|
diagnostics_update_in_insert = mkOption {
|
||||||
|
type = bool;
|
||||||
|
default = false;
|
||||||
|
description = ''
|
||||||
|
Whether to update diagnostics while in insert mode.
|
||||||
|
|
||||||
|
Setting this to true has performance implications, but they may be
|
||||||
|
negligible depending on your setup. Set it to true if you know what
|
||||||
|
you are doing.
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
|
diagnostics_indicator = mkOption {
|
||||||
|
type = nullOr luaInline;
|
||||||
|
default = lib.generators.mkLuaInline ''
|
||||||
|
function(count, level, diagnostics_dict, context)
|
||||||
|
local s = " "
|
||||||
|
for e, n in pairs(diagnostics_dict) do
|
||||||
|
local sym = e == "error" and " "
|
||||||
|
or (e == "warning" and " " or " " )
|
||||||
|
s = s .. n .. sym
|
||||||
|
end
|
||||||
|
return s
|
||||||
|
end
|
||||||
|
'';
|
||||||
|
|
||||||
|
description = ''
|
||||||
|
Function to get the diagnostics indicator.
|
||||||
|
The function should return a string to be used as the indicator.
|
||||||
|
|
||||||
|
Can be set to nil to keep the buffer name highlight, but delete the
|
||||||
|
highlighting.
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
|
custom_filter = mkOption {
|
||||||
|
type = nullOr luaInline;
|
||||||
|
default = null;
|
||||||
|
example = literalExpression lib.generators.mkLuaInline ''
|
||||||
|
custom_filter = function(buf_number, buf_numbers)
|
||||||
|
-- filter out filetypes you don't want to see
|
||||||
|
if vim.bo[buf_number].filetype ~= "<i-dont-want-to-see-this>" then
|
||||||
|
return true
|
||||||
|
end
|
||||||
|
-- filter out by buffer name
|
||||||
|
if vim.fn.bufname(buf_number) ~= "<buffer-name-I-dont-want>" then
|
||||||
|
return true
|
||||||
|
end
|
||||||
|
-- filter out based on arbitrary rules
|
||||||
|
-- e.g. filter out vim wiki buffer from tabline in your work repo
|
||||||
|
if vim.fn.getcwd() == "<work-repo>" and vim.bo[buf_number].filetype ~= "wiki" then
|
||||||
|
return true
|
||||||
|
end
|
||||||
|
-- filter out by it's index number in list (don't show first buffer)
|
||||||
|
if buf_numbers[1] ~= buf_number then
|
||||||
|
return true
|
||||||
|
end
|
||||||
|
end
|
||||||
|
'';
|
||||||
|
|
||||||
|
description = ''
|
||||||
|
Custom filter function for filtering out buffers.
|
||||||
|
|
||||||
|
::: {.note}
|
||||||
|
This will be called a lot, so you are encouraged to keep it as
|
||||||
|
short and lightweight as possible unless you are fully aware
|
||||||
|
of the performance implications.
|
||||||
|
:::
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
|
color_icons = mkOption {
|
||||||
|
type = bool;
|
||||||
|
default = true;
|
||||||
|
description = "Whether or not to add filetype icon highlights";
|
||||||
|
};
|
||||||
|
|
||||||
|
show_buffer_icons = mkOption {
|
||||||
|
type = bool;
|
||||||
|
default = true;
|
||||||
|
description = "Whether or not to show buffer icons";
|
||||||
|
};
|
||||||
|
|
||||||
|
show_buffer_close_icons = mkOption {
|
||||||
|
type = bool;
|
||||||
|
default = true;
|
||||||
|
description = "Whether or not to show buffer close icons";
|
||||||
|
};
|
||||||
|
|
||||||
|
show_close_icon = mkOption {
|
||||||
|
type = bool;
|
||||||
|
default = true;
|
||||||
|
description = "Whether or not to show close icon";
|
||||||
|
};
|
||||||
|
|
||||||
|
show_tab_indicators = mkOption {
|
||||||
|
type = bool;
|
||||||
|
default = true;
|
||||||
|
description = "Whether or not to show tab indicators";
|
||||||
|
};
|
||||||
|
|
||||||
|
show_duplicate_prefix = mkOption {
|
||||||
|
type = bool;
|
||||||
|
default = true;
|
||||||
|
description = "Whether or not to show duplicate prefix";
|
||||||
|
};
|
||||||
|
|
||||||
|
duplicates_across_groups = mkOption {
|
||||||
|
type = bool;
|
||||||
|
default = true;
|
||||||
|
description = "Whether to consider duplicate paths in different groups as duplicates";
|
||||||
|
};
|
||||||
|
|
||||||
|
persist_buffer_sort = mkOption {
|
||||||
|
type = bool;
|
||||||
|
default = true;
|
||||||
|
description = "Whether or not custom sorted buffers should persist";
|
||||||
|
};
|
||||||
|
|
||||||
|
move_wraps_at_ends = mkOption {
|
||||||
|
type = bool;
|
||||||
|
default = false;
|
||||||
|
description = "Whether or not the move command \"wraps\" at the first or last position";
|
||||||
|
};
|
||||||
|
|
||||||
|
seperator_style = mkOption {
|
||||||
|
type = either (enum ["thick" "thin" "slope" "slant"]) (listOf str);
|
||||||
|
default = [" " " "];
|
||||||
|
description = ''
|
||||||
|
Style of the buffer separator.
|
||||||
|
|
||||||
|
Can be either one of the suspported values, or a list containing
|
||||||
|
**at most** two elements for `focused` and `unfocused` respectively.
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
|
enforce_regular_tabs = mkOption {
|
||||||
|
type = bool;
|
||||||
|
default = false;
|
||||||
|
description = "Whether to enforce regular tabs";
|
||||||
|
};
|
||||||
|
|
||||||
|
always_show_bufferline = mkOption {
|
||||||
|
type = bool;
|
||||||
|
default = true;
|
||||||
|
description = "Whether to always show bufferline";
|
||||||
|
};
|
||||||
|
|
||||||
|
auto_toggle_bufferline = mkOption {
|
||||||
|
type = bool;
|
||||||
|
default = false;
|
||||||
|
description = "Whether to auto toggle bufferline";
|
||||||
|
};
|
||||||
|
|
||||||
|
hover = {
|
||||||
|
enabled = mkEnableOption "hover" // {default = true;};
|
||||||
|
delay = mkOption {
|
||||||
|
type = int;
|
||||||
|
default = 200;
|
||||||
|
description = "Delay for hover, in ms";
|
||||||
|
};
|
||||||
|
|
||||||
|
reveal = mkOption {
|
||||||
|
type = listOf str;
|
||||||
|
default = ["close"];
|
||||||
|
description = "Reveal hover window";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
sort_by = mkOption {
|
||||||
|
type = either (enum ["insert_after_current" "insert_at_end" "id" "extension" "relative_directory" "directory" "tabs"]) luaInline;
|
||||||
|
default = "extension";
|
||||||
|
description = "Method to sort buffers by. Must be one of the supported valuees, or an inline Lua value.";
|
||||||
|
};
|
||||||
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -30,9 +30,9 @@ in {
|
||||||
normal = mkSetBinding mappings.incrementalSelection.init ":lua require('nvim-treesitter.incremental_selection').init_selection()<CR>";
|
normal = mkSetBinding mappings.incrementalSelection.init ":lua require('nvim-treesitter.incremental_selection').init_selection()<CR>";
|
||||||
|
|
||||||
visualOnly = mkMerge [
|
visualOnly = mkMerge [
|
||||||
(mkSetBinding mappings.incrementalSelection.incrementByNode ":lua require('nvim-treesitter.incremental_selection').node_incremental()<CR>")
|
(mkSetBinding mappings.incrementalSelection.incrementByNode "<cmd>lua require('nvim-treesitter.incremental_selection').node_incremental()<CR>")
|
||||||
(mkSetBinding mappings.incrementalSelection.incrementByScope ":lua require('nvim-treesitter.incremental_selection').scope_incremental()<CR>")
|
(mkSetBinding mappings.incrementalSelection.incrementByScope "<cmd>lua require('nvim-treesitter.incremental_selection').scope_incremental()<CR>")
|
||||||
(mkSetBinding mappings.incrementalSelection.decrementByNode ":lua require('nvim-treesitter.incremental_selection').node_decremental()<CR>")
|
(mkSetBinding mappings.incrementalSelection.decrementByNode "<cmd>lua require('nvim-treesitter.incremental_selection').node_decremental()<CR>")
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -1,53 +0,0 @@
|
||||||
{
|
|
||||||
pkgs,
|
|
||||||
lib,
|
|
||||||
...
|
|
||||||
}: let
|
|
||||||
inherit (lib) mkMappingOption mkEnableOption mkOption types;
|
|
||||||
in {
|
|
||||||
options.vim.telescope = {
|
|
||||||
mappings = {
|
|
||||||
findProjects = mkMappingOption "Find files [Telescope]" "<leader>fp";
|
|
||||||
|
|
||||||
findFiles = mkMappingOption "Find files [Telescope]" "<leader>ff";
|
|
||||||
liveGrep = mkMappingOption "Live grep [Telescope]" "<leader>fg";
|
|
||||||
buffers = mkMappingOption "Buffers [Telescope]" "<leader>fb";
|
|
||||||
helpTags = mkMappingOption "Help tags [Telescope]" "<leader>fh";
|
|
||||||
open = mkMappingOption "Open [Telescope]" "<leader>ft";
|
|
||||||
|
|
||||||
gitCommits = mkMappingOption "Git commits [Telescope]" "<leader>fvcw";
|
|
||||||
gitBufferCommits = mkMappingOption "Git buffer commits [Telescope]" "<leader>fvcb";
|
|
||||||
gitBranches = mkMappingOption "Git branches [Telescope]" "<leader>fvb";
|
|
||||||
gitStatus = mkMappingOption "Git status [Telescope]" "<leader>fvs";
|
|
||||||
gitStash = mkMappingOption "Git stash [Telescope]" "<leader>fvx";
|
|
||||||
|
|
||||||
lspDocumentSymbols = mkMappingOption "LSP Document Symbols [Telescope]" "<leader>flsb";
|
|
||||||
lspWorkspaceSymbols = mkMappingOption "LSP Workspace Symbols [Telescope]" "<leader>flsw";
|
|
||||||
lspReferences = mkMappingOption "LSP References [Telescope]" "<leader>flr";
|
|
||||||
lspImplementations = mkMappingOption "LSP Implementations [Telescope]" "<leader>fli";
|
|
||||||
lspDefinitions = mkMappingOption "LSP Definitions [Telescope]" "<leader>flD";
|
|
||||||
lspTypeDefinitions = mkMappingOption "LSP Type Definitions [Telescope]" "<leader>flt";
|
|
||||||
diagnostics = mkMappingOption "Diagnostics [Telescope]" "<leader>fld";
|
|
||||||
|
|
||||||
treesitter = mkMappingOption "Treesitter [Telescope]" "<leader>fs";
|
|
||||||
};
|
|
||||||
|
|
||||||
enable = mkEnableOption "telescope.nvim: multi-purpose search and picker utility";
|
|
||||||
|
|
||||||
vimgrep_arguments = mkOption {
|
|
||||||
description = "Arguments to use for the grep command";
|
|
||||||
type = types.listOf types.str;
|
|
||||||
default = [
|
|
||||||
"${pkgs.ripgrep}/bin/rg"
|
|
||||||
"--color=never"
|
|
||||||
"--no-heading"
|
|
||||||
"--with-filename"
|
|
||||||
"--line-number"
|
|
||||||
"--column"
|
|
||||||
"--smart-case"
|
|
||||||
"--hidden"
|
|
||||||
"--no-ignore"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -3,7 +3,7 @@
|
||||||
lib,
|
lib,
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
inherit (lib.options) mkOption mkEnableOption literalExpression;
|
inherit (lib.options) mkOption mkEnableOption literalMD;
|
||||||
inherit (lib.types) package bool str listOf attrsOf;
|
inherit (lib.types) package bool str listOf attrsOf;
|
||||||
inherit (lib.nvim.types) pluginsOpt extraPluginType;
|
inherit (lib.nvim.types) pluginsOpt extraPluginType;
|
||||||
in {
|
in {
|
||||||
|
@ -38,7 +38,7 @@ in {
|
||||||
|
|
||||||
startPlugins = pluginsOpt {
|
startPlugins = pluginsOpt {
|
||||||
default = ["plenary-nvim"];
|
default = ["plenary-nvim"];
|
||||||
example = literalExpression ''
|
example = ''
|
||||||
[pkgs.vimPlugins.telescope-nvim]
|
[pkgs.vimPlugins.telescope-nvim]
|
||||||
'';
|
'';
|
||||||
|
|
||||||
|
@ -54,7 +54,7 @@ in {
|
||||||
|
|
||||||
optPlugins = pluginsOpt {
|
optPlugins = pluginsOpt {
|
||||||
default = [];
|
default = [];
|
||||||
example = literalExpression ''
|
example = ''
|
||||||
[pkgs.vimPlugins.vim-ghost]
|
[pkgs.vimPlugins.vim-ghost]
|
||||||
'';
|
'';
|
||||||
description = ''
|
description = ''
|
||||||
|
@ -80,7 +80,8 @@ in {
|
||||||
your custom plugins using nvf's modified DAG library.
|
your custom plugins using nvf's modified DAG library.
|
||||||
'';
|
'';
|
||||||
|
|
||||||
example = literalExpression ''
|
example = literalMD ''
|
||||||
|
```nix
|
||||||
with pkgs.vimPlugins; {
|
with pkgs.vimPlugins; {
|
||||||
aerial = {
|
aerial = {
|
||||||
package = aerial-nvim;
|
package = aerial-nvim;
|
||||||
|
@ -93,13 +94,14 @@ in {
|
||||||
after = ["aerial"]; # place harpoon configuration after aerial
|
after = ["aerial"]; # place harpoon configuration after aerial
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
```
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
extraPackages = mkOption {
|
extraPackages = mkOption {
|
||||||
type = listOf package;
|
type = listOf package;
|
||||||
default = [];
|
default = [];
|
||||||
example = literalExpression ''[pkgs.fzf pkgs.ripgrep]'';
|
example = ''[pkgs.fzf pkgs.ripgrep]'';
|
||||||
description = ''
|
description = ''
|
||||||
List of additional packages to make available to the Neovim
|
List of additional packages to make available to the Neovim
|
||||||
wrapper.
|
wrapper.
|
||||||
|
@ -107,7 +109,7 @@ in {
|
||||||
};
|
};
|
||||||
|
|
||||||
# this defaults to `true` in the wrapper
|
# this defaults to `true` in the wrapper
|
||||||
# and since we passs this value to the wrapper
|
# and since we pass this value to the wrapper
|
||||||
# with an inherit, it should be `true` here as well
|
# with an inherit, it should be `true` here as well
|
||||||
withRuby =
|
withRuby =
|
||||||
mkEnableOption ''
|
mkEnableOption ''
|
||||||
|
@ -118,29 +120,25 @@ in {
|
||||||
};
|
};
|
||||||
|
|
||||||
withNodeJs = mkEnableOption ''
|
withNodeJs = mkEnableOption ''
|
||||||
NodeJs support in the Neovim wrapper.
|
NodeJs support in the Neovim wrapper
|
||||||
'';
|
'';
|
||||||
|
|
||||||
luaPackages = mkOption {
|
luaPackages = mkOption {
|
||||||
type = listOf str;
|
type = listOf str;
|
||||||
default = [];
|
default = [];
|
||||||
example = literalExpression ''["magick" "serpent"]'';
|
example = ''["magick" "serpent"]'';
|
||||||
description = ''
|
description = "List of lua packages to install";
|
||||||
List of lua packages to install.
|
|
||||||
'';
|
|
||||||
};
|
};
|
||||||
|
|
||||||
withPython3 = mkEnableOption ''
|
withPython3 = mkEnableOption ''
|
||||||
Python3 support in the Neovim wrapper.
|
Python3 support in the Neovim wrapper
|
||||||
'';
|
'';
|
||||||
|
|
||||||
python3Packages = mkOption {
|
python3Packages = mkOption {
|
||||||
type = listOf str;
|
type = listOf str;
|
||||||
default = [];
|
default = [];
|
||||||
example = literalExpression ''["pynvim"]'';
|
example = ''["pynvim"]'';
|
||||||
description = ''
|
description = "List of python packages to install";
|
||||||
List of python packages to install.
|
|
||||||
'';
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -133,6 +133,14 @@ in {
|
||||||
configRC = {
|
configRC = {
|
||||||
globalsScript = entryAnywhere (concatStringsSep "\n" globalsScript);
|
globalsScript = entryAnywhere (concatStringsSep "\n" globalsScript);
|
||||||
|
|
||||||
|
# Call additional lua files with :luafile in Vimscript
|
||||||
|
# section of the configuration, only after
|
||||||
|
# the luaScript section has been evaluated
|
||||||
|
extraLuaFiles = let
|
||||||
|
callLuaFiles = map (file: "luafile ${file}") cfg.extraLuaFiles;
|
||||||
|
in
|
||||||
|
entryAfter ["globalScript"] (concatStringsSep "\n" callLuaFiles);
|
||||||
|
|
||||||
# wrap the lua config in a lua block
|
# wrap the lua config in a lua block
|
||||||
# using the wrapLuaConfic function from the lib
|
# using the wrapLuaConfic function from the lib
|
||||||
luaScript = let
|
luaScript = let
|
||||||
|
@ -148,7 +156,7 @@ in {
|
||||||
inherit mapResult;
|
inherit mapResult;
|
||||||
};
|
};
|
||||||
in
|
in
|
||||||
entryAfter ["globalsScript"] luaConfig;
|
entryAnywhere luaConfig;
|
||||||
|
|
||||||
extraPluginConfigs = let
|
extraPluginConfigs = let
|
||||||
mapResult = result: (wrapLuaConfig {
|
mapResult = result: (wrapLuaConfig {
|
||||||
|
|
|
@ -37,8 +37,8 @@ in {
|
||||||
To avoid leaking imperative user configuration into your
|
To avoid leaking imperative user configuration into your
|
||||||
configuration, this is enabled by default. If you wish
|
configuration, this is enabled by default. If you wish
|
||||||
to load configuration from user configuration directories
|
to load configuration from user configuration directories
|
||||||
(e.g. `$HOME/.config/nvim`, `$HOME/.config/nvim/after`
|
(e.g. {file}`$HOME/.config/nvim`, {file}`$HOME/.config/nvim/after`
|
||||||
and `$HOME/.local/share/nvim/site`) you may set this
|
and {file}`$HOME/.local/share/nvim/site`) you may set this
|
||||||
option to true.
|
option to true.
|
||||||
:::
|
:::
|
||||||
'';
|
'';
|
||||||
|
@ -68,16 +68,52 @@ in {
|
||||||
active runtimepath of the Neovim. This can be used to
|
active runtimepath of the Neovim. This can be used to
|
||||||
add additional lookup paths for configs, plugins, spell
|
add additional lookup paths for configs, plugins, spell
|
||||||
languages and other things you would generally place in
|
languages and other things you would generally place in
|
||||||
your `$HOME/.config/nvim`.
|
your {file}`$HOME/.config/nvim`.
|
||||||
|
|
||||||
This is meant as a declarative alternative to throwing
|
This is meant as a declarative alternative to throwing
|
||||||
files into `~/.config/nvim` and having the Neovim
|
files into {file}`~/.config/nvim` and having the Neovim
|
||||||
wrapper pick them up. For more details on
|
wrapper pick them up. For more details on
|
||||||
`vim.o.runtimepath`, and what paths to use; please see
|
`vim.o.runtimepath`, and what paths to use; please see
|
||||||
[the official documentation](https://neovim.io/doc/user/options.html#'runtimepath')
|
[the official documentation](https://neovim.io/doc/user/options.html#'runtimepath')
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
|
extraLuaFiles = mkOption {
|
||||||
|
type = listOf (either path str);
|
||||||
|
default = [];
|
||||||
|
example = literalExpression ''
|
||||||
|
[
|
||||||
|
# absolute path, as a string - impure
|
||||||
|
"$HOME/.config/nvim/my-lua-file.lua"
|
||||||
|
|
||||||
|
# relative path, as a path - pure
|
||||||
|
./nvim/my-lua-file.lua
|
||||||
|
|
||||||
|
# source type path - pure and reproducible
|
||||||
|
(builtins.source {
|
||||||
|
path = ./nvim/my-lua-file.lua;
|
||||||
|
name = "my-lua-file";
|
||||||
|
})
|
||||||
|
]
|
||||||
|
'';
|
||||||
|
|
||||||
|
description = ''
|
||||||
|
Additional lua files that will be sourced by Neovim.
|
||||||
|
Takes both absolute and relative paths, all of which
|
||||||
|
will be called via the `luafile` command in Neovim.
|
||||||
|
|
||||||
|
See [lua-commands](https://neovim.io/doc/user/lua.html#lua-commands)
|
||||||
|
on the Neovim documentation for more details.
|
||||||
|
|
||||||
|
::: {.warning}
|
||||||
|
All paths passed to this option must be valid. If Neovim cannot
|
||||||
|
resolve the path you are attempting to sourcee, then your configuration
|
||||||
|
will error, and Neovim will not start. Please ensure that all paths
|
||||||
|
are correct before using this option.
|
||||||
|
:::
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
globals = mkOption {
|
globals = mkOption {
|
||||||
type = attrs;
|
type = attrs;
|
||||||
default = {};
|
default = {};
|
||||||
|
|
Loading…
Reference in a new issue