2022-08-10 08:20:23 +00:00
|
|
|
{
|
|
|
|
pkgs,
|
|
|
|
lib,
|
|
|
|
...
|
|
|
|
}:
|
2022-08-09 15:30:56 +00:00
|
|
|
with lib;
|
2022-08-10 08:20:23 +00:00
|
|
|
with builtins; let
|
|
|
|
getNixFiles = dir: let
|
|
|
|
recu = n: k:
|
|
|
|
if k == "directory"
|
|
|
|
then getNixFiles "${dir}/${n}"
|
|
|
|
else if hasSuffix "nix" n
|
|
|
|
then ["${dir}/${n}"]
|
|
|
|
else [];
|
|
|
|
in
|
|
|
|
flatten (mapAttrsToList recu (readDir dir));
|
2022-08-09 15:30:56 +00:00
|
|
|
in {
|
|
|
|
imports = getNixFiles ./modules;
|
|
|
|
|
|
|
|
treesitter.enable = true;
|
|
|
|
|
|
|
|
vim.opt = {
|
|
|
|
wrap = true;
|
|
|
|
lbr = true;
|
|
|
|
timeoutlen = 400;
|
|
|
|
};
|
|
|
|
|
|
|
|
output.path.style = "impure";
|
|
|
|
output.makeWrapper = "--set LUA_PATH '${./modules/lua}/?.lua;;'";
|
2022-08-10 08:20:23 +00:00
|
|
|
output.path.path = with pkgs; [wl-clipboard];
|
2022-08-09 15:30:56 +00:00
|
|
|
|
|
|
|
output.extraConfig = ''
|
|
|
|
" Keybindings
|
|
|
|
:lua require'keybindings'
|
|
|
|
|
|
|
|
" TODO: Set clipboard tool with g:clipboard
|
|
|
|
'';
|
|
|
|
}
|
|
|
|
# TODO:
|
|
|
|
# https://idie.ru/posts/vim-modern-cpp
|
2022-08-10 08:20:23 +00:00
|
|
|
|