Compare commits

..

No commits in common. "26887e2f33d3cacda7ee147895fefc4371c218a4" and "21954357531ba530180c44af35da495306211248" have entirely different histories.

View file

@ -4,17 +4,15 @@ let
inherit (lib.mod) ctrl; inherit (lib.mod) ctrl;
inherit (lib.nix2lua) pipe1 require call call0 nf var; inherit (lib.nix2lua) pipe1 require call call0 nf var;
mkLineLimiterOpts = limit: {
colorcolumn = toString (limit + 1);
textwidth = limit;
};
mkLineLimiterGroup = { limit, pattern }: mkLineLimiterGroup = { limit, pattern }:
lib.nameValuePair lib.nameValuePair
"line-limiter-${toString limit}" "line-limiter-${toString limit}"
{ {
inherit pattern; inherit pattern;
opt = mkLineLimiterOpts limit; opt = {
colorcolumn = toString limit;
textwidth = limit - 1;
};
}; };
in in
{ {
@ -25,17 +23,11 @@ in
vim.opt = { vim.opt = {
list = true; list = true;
formatoptions = "tcroqwanljp";
}; };
buffer.filetype = { buffer.filetype = lib.listToAttrs [
python-options = {
pattern = [ "python" ];
opt = { formatoptions = "croqwaljp"; } // mkLineLimiterOpts 90;
};
} // lib.listToAttrs [
(mkLineLimiterGroup { (mkLineLimiterGroup {
limit = 100; limit = 101;
pattern = [ pattern = [
"nix" "nix"
"javascript,javascriptreact" "javascript,javascriptreact"
@ -45,8 +37,9 @@ in
]; ];
}) })
(mkLineLimiterGroup { (mkLineLimiterGroup {
limit = 80; limit = 81;
pattern = [ pattern = [
"python"
"json" "json"
"yaml" "yaml"
"markdown" "markdown"
@ -66,12 +59,6 @@ in
# Enable fast navigation between windows # Enable fast navigation between windows
vim.keymap.set = map (k: { mode = "n"; lhs = ctrl k; rhs = "${ctrl "w"}${k}"; }) [ "h" "l" "j" "k" ]; vim.keymap.set = map (k: { mode = "n"; lhs = ctrl k; rhs = "${ctrl "w"}${k}"; }) [ "h" "l" "j" "k" ];
plugin.nlsp-settings-nvim = {
enable = true;
name = "nlspsettings";
setupSettings = { };
};
plugins.style.nvim-treesitter.extraGrammars = { plugins.style.nvim-treesitter.extraGrammars = {
tree-sitter-d2 = rec { tree-sitter-d2 = rec {
language = "d2"; language = "d2";