Merge branch 'main' into notashelf/push-qozvyzsvqtmk

This commit is contained in:
raf 2026-04-04 21:00:17 +03:00 committed by GitHub
commit 0f302adf64
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
41 changed files with 1214 additions and 506 deletions

View file

@ -25,14 +25,14 @@ jobs:
name: Checkout name: Checkout
- name: Install Nix - name: Install Nix
uses: cachix/install-nix-action@v31.10.1 uses: cachix/install-nix-action@v31.10.3
with: with:
nix_path: nixpkgs=channel:nixos-unstable nix_path: nixpkgs=channel:nixos-unstable
extra_nix_config: | extra_nix_config: |
substituters = https://cache.nixos.org/ https://feel-co.cachix.org substituters = https://cache.nixos.org/ https://feel-co.cachix.org
trusted-public-keys = cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY= feel-co.cachix.org-1:nwEFNnwZvtl4KKSH5LDg+/+K7bV0vcs6faMHAJ6xx0w= trusted-public-keys = cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY= feel-co.cachix.org-1:nwEFNnwZvtl4KKSH5LDg+/+K7bV0vcs6faMHAJ6xx0w=
- uses: cachix/cachix-action@v16 - uses: cachix/cachix-action@v17
with: with:
authToken: ${{ secrets.CACHIX_TOKEN }} authToken: ${{ secrets.CACHIX_TOKEN }}
extraPullNames: nix-community extraPullNames: nix-community

View file

@ -18,7 +18,7 @@ jobs:
steps: steps:
- name: Checkout - name: Checkout
uses: actions/checkout@v6 uses: actions/checkout@v6
- uses: cachix/install-nix-action@v31.10.1 - uses: cachix/install-nix-action@v31.10.3
with: with:
nix_path: nixpkgs=channel:nixos-unstable nix_path: nixpkgs=channel:nixos-unstable
extra_nix_config: | extra_nix_config: |
@ -37,7 +37,7 @@ jobs:
uses: actions/checkout@v6 uses: actions/checkout@v6
- name: Install Nix - name: Install Nix
uses: cachix/install-nix-action@v31.10.1 uses: cachix/install-nix-action@v31.10.3
with: with:
nix_path: nixpkgs=channel:nixos-unstable nix_path: nixpkgs=channel:nixos-unstable
extra_nix_config: | extra_nix_config: |
@ -93,14 +93,14 @@ jobs:
steps: steps:
- name: Checkout - name: Checkout
uses: actions/checkout@v6 uses: actions/checkout@v6
- uses: cachix/install-nix-action@v31.10.1 - uses: cachix/install-nix-action@v31.10.3
with: with:
nix_path: nixpkgs=channel:nixos-unstable nix_path: nixpkgs=channel:nixos-unstable
extra_nix_config: | extra_nix_config: |
substituters = https://cache.nixos.org/ https://feel-co.cachix.org substituters = https://cache.nixos.org/ https://feel-co.cachix.org
trusted-public-keys = cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY= feel-co.cachix.org-1:nwEFNnwZvtl4KKSH5LDg+/+K7bV0vcs6faMHAJ6xx0w= trusted-public-keys = cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY= feel-co.cachix.org-1:nwEFNnwZvtl4KKSH5LDg+/+K7bV0vcs6faMHAJ6xx0w=
- uses: cachix/cachix-action@v16 - uses: cachix/cachix-action@v17
with: with:
authToken: ${{ secrets.CACHIX_TOKEN }} authToken: ${{ secrets.CACHIX_TOKEN }}
extraPullNames: nix-community extraPullNames: nix-community
@ -131,7 +131,7 @@ jobs:
steps: steps:
- name: Checkout - name: Checkout
uses: actions/checkout@v6 uses: actions/checkout@v6
- uses: cachix/install-nix-action@v31.10.1 - uses: cachix/install-nix-action@v31.10.3
with: with:
nix_path: nixpkgs=channel:nixos-unstable nix_path: nixpkgs=channel:nixos-unstable
extra_nix_config: | extra_nix_config: |
@ -169,7 +169,7 @@ jobs:
cat "$HOME/changed_files" cat "$HOME/changed_files"
- name: Install Nix - name: Install Nix
uses: cachix/install-nix-action@v31.10.1 uses: cachix/install-nix-action@v31.10.3
with: with:
nix_path: nixpkgs=channel:nixos-unstable nix_path: nixpkgs=channel:nixos-unstable
extra_nix_config: | extra_nix_config: |

View file

@ -25,7 +25,7 @@ jobs:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: actions/checkout@v6 - uses: actions/checkout@v6
- uses: cachix/install-nix-action@v31.10.1 - uses: cachix/install-nix-action@v31.10.3
with: with:
nix_path: nixpkgs=channel:nixos-unstable nix_path: nixpkgs=channel:nixos-unstable
extra_nix_config: | extra_nix_config: |

View file

@ -44,7 +44,7 @@ jobs:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: actions/checkout@v6 - uses: actions/checkout@v6
- uses: cachix/install-nix-action@v31.10.1 - uses: cachix/install-nix-action@v31.10.3
with: with:
nix_path: nixpkgs=channel:nixos-unstable nix_path: nixpkgs=channel:nixos-unstable
extra_nix_config: | extra_nix_config: |

View file

@ -12,7 +12,7 @@ jobs:
uses: actions/checkout@v6 uses: actions/checkout@v6
- name: "Install Nix" - name: "Install Nix"
uses: cachix/install-nix-action@v31.10.1 uses: cachix/install-nix-action@v31.10.3
- name: Set up Git - name: Set up Git
run: | run: |

View file

@ -13,6 +13,9 @@ isMaximal: {
logFile = "/tmp/nvim.log"; logFile = "/tmp/nvim.log";
}; };
# vim.opts and vim.options are aliased
opts.expandtab = true;
spellcheck = { spellcheck = {
enable = true; enable = true;
programmingWordlist.enable = isMaximal; programmingWordlist.enable = isMaximal;
@ -74,8 +77,10 @@ isMaximal: {
}; };
toml.enable = isMaximal; toml.enable = isMaximal;
xml.enable = isMaximal; xml.enable = isMaximal;
tex.enable = isMaximal;
# Language modules that are not as common. # Language modules that are not as common.
openscad.enable = false;
arduino.enable = false; arduino.enable = false;
assembly.enable = false; assembly.enable = false;
astro.enable = false; astro.enable = false;
@ -100,9 +105,12 @@ isMaximal: {
jinja.enable = false; jinja.enable = false;
tailwind.enable = false; tailwind.enable = false;
svelte.enable = false; svelte.enable = false;
liquid.enable = false;
tera.enable = false; tera.enable = false;
twig.enable = false; twig.enable = false;
gettext.enable = false;
fluent.enable = false; fluent.enable = false;
jq.enable = false;
# Nim LSP is broken on Darwin and therefore # Nim LSP is broken on Darwin and therefore
# should be disabled by default. Users may still enable # should be disabled by default. Users may still enable

View file

@ -52,7 +52,7 @@ the default theme enabled. You may use other options inside `config.vim` in
# Can also move this to another config file if you pass your own # Can also move this to another config file if you pass your own
# inputs/self around with specialArgs # inputs/self around with specialArgs
({pkgs, ...}: { ({pkgs, ...}: {
environment.systemPackages = [self.packages.${pkgs.stdenv.system}.neovim]; environment.systemPackages = [self.packages.${pkgs.stdenv.hostPlatform.system}.my-neovim];
}) })
]; ];
# ... # ...

View file

@ -6,6 +6,7 @@
`vimPlugins.nvim-treesitter`. Namely, it changes from the frozen `master` `vimPlugins.nvim-treesitter`. Namely, it changes from the frozen `master`
branch to the new main branch. This change removes incremental selections, so branch to the new main branch. This change removes incremental selections, so
it is no longer available. it is no longer available.
- [obsidian.nvim] now uses a maintained fork which has removed the `dir` - [obsidian.nvim] now uses a maintained fork which has removed the `dir`
setting. Use `workspaces` instead: setting. Use `workspaces` instead:
@ -21,16 +22,22 @@
``` ```
Some other settings and commands are now deprecated but are still supported. Some other settings and commands are now deprecated but are still supported.
- The `setupOpts.mappings` options were also removed. Use the built-in Neovim - The `setupOpts.mappings` options were also removed. Use the built-in Neovim
settings (nvf's {option}`vim.keymaps`) settings (nvf's {option}`vim.keymaps`)
- `languages.{terraform,hcl}`: LSP servers now default to `tofu-ls`. While this
is unlikely to cause any noticeable change in behavior or breakage, it's
mentioned just in case.
- `vim.treesitter.foldByDefault` is removed. Folding behavior should be
controlled via `vim.options.foldenable` directly instead. RIP
`vim.treesitter.foldByDefault` 2026-03-19 - 2026-03-19.
[Snoweuph](https://github.com/snoweuph) [Snoweuph](https://github.com/snoweuph)
- "Correct `languages.go.treesitter` to contain all Go file types. - "Correct `languages.go.treesitter` to contain all Go file types.
`languages.go.treesitter.package` is now `languages.go.treesitter.goPackage`. `languages.go.treesitter.package` is now `languages.go.treesitter.goPackage`.
New are: New are:
- `languages.go.treesitter.goPackage`. - `languages.go.treesitter.goPackage`.
- `languages.go.treesitter.gomodPackage`. - `languages.go.treesitter.gomodPackage`.
@ -52,6 +59,15 @@
## Changelog {#sec-release-0-9-changelog} ## Changelog {#sec-release-0-9-changelog}
[midischwarz12](https://github.com/midischwarz12):
- Changed the prettier-plugin-astro build to use `writableTmpDirAsHomeHook` to
avoid pnpm hook failures in sandboxed builds.
- Fix `vim.utility.leetcode-nvim` adding `fzf-lua` to `vim.startPlugins` when
`vim.fzf-lua` already manages the plugin lazily, avoiding duplicate `/start`
and `/opt` installs and the corresponding `mnw` evaluation warning.
[taylrfnt](https://github.com/taylrfnt) [taylrfnt](https://github.com/taylrfnt)
- Introduce a `darwinModule` option for Darwin users. The ergonomics of - Introduce a `darwinModule` option for Darwin users. The ergonomics of
@ -60,7 +76,7 @@
following: following:
```shell ```shell
(class: "nixos") cannot be imported into a module (class: "nixos") cannot be imported into a module
evaluation that expects class "darwin". evaluation that expects class "darwin".
``` ```
@ -78,6 +94,8 @@
[NotAShelf](https://github.com/notashelf): [NotAShelf](https://github.com/notashelf):
- Lazyload noice.nvim and nvim-web-devicons on `DeferredUIEnter` - Lazyload noice.nvim and nvim-web-devicons on `DeferredUIEnter`
- Allow nulling treesitter packages for various language modules, filter `null`
values in `vim.treesitter.grammars`.
[jfeo](https://github.com/jfeo): [jfeo](https://github.com/jfeo):
@ -96,6 +114,14 @@
- `toggleterm` open map now also works when in terminal mode - `toggleterm` open map now also works when in terminal mode
[ppenguin](https://github.com/ppenguin):
- Improved/harmonized for `terraform` and `hcl`:
- formatting (use `terraform fmt` or `tofu fmt` for `tf` files)
- LSP config
- Added `tofu` and `tofu-ls` as (free) alternative to `terrraform` and
`terraform-ls`
[jtliang24](https://github.com/jtliang24): [jtliang24](https://github.com/jtliang24):
- Updated nix language plugin to use pkgs.nixfmt instead of - Updated nix language plugin to use pkgs.nixfmt instead of
@ -145,7 +171,9 @@
- Mappings are now expected to be set using the built-in Neovim APIs, - Mappings are now expected to be set using the built-in Neovim APIs,
managed by `vim.keymaps` in nvf, instead of `mappings` options. managed by `vim.keymaps` in nvf, instead of `mappings` options.
- Some option defaults have changed. - Some option defaults have changed.
- And more. - And more.
- Automatically configure an enabled picker in the order mentioned above, if - Automatically configure an enabled picker in the order mentioned above, if
any are enabled. any are enabled.
- Add integration with `snacks.image` for rendering workspace/vault assets. - Add integration with `snacks.image` for rendering workspace/vault assets.
@ -201,6 +229,9 @@
- Added [tera](https://keats.github.io/tera/) language support (syntax - Added [tera](https://keats.github.io/tera/) language support (syntax
highlighting only). highlighting only).
- Added [liquid](https://keats.github.io/tera/) language support (syntax
highlighting only) via `languages.liquid`.
- Added Debugging support to `languages.odin` with - Added Debugging support to `languages.odin` with
[nvim-dap-odin](https://github.com/NANDquark/nvim-dap-odin). [nvim-dap-odin](https://github.com/NANDquark/nvim-dap-odin).
@ -222,9 +253,26 @@
- Fix `languages.hcl` init, depending on `comment-nvim` by checking if it is - Fix `languages.hcl` init, depending on `comment-nvim` by checking if it is
enabled. Fixes a crash (#1350). enabled. Fixes a crash (#1350).
- Added [`tsgo`](https://github.com/microsoft/typescript-go) as an LSP to
`languages.ts`.
- Fix `languages.ts` registration of formatters.
- Added `biome-check` and `biome-organize-imports` formatters to `languages.ts`.
- Added [`biomejs`](https://biomejs.dev/) as extra diagnostics provider to
`languages.ts`.
- Add `languages.fluent` using the official plugin. This only provides - Add `languages.fluent` using the official plugin. This only provides
highlighting. highlighting.
- Add `languages.gettext`. This only provides highlighting.
- Add `languages.openscad` using
[`openscad-lsp`](https://github.com/Leathong/openscad-LSP). This currently
relies on neovim builtin syntax for highlighting, and the lsp for formatting
and diagnostics.
- Added Debugging support to `languages.php`. - Added Debugging support to `languages.php`.
- Added Formatting support to `languages.php` via - Added Formatting support to `languages.php` via
@ -235,10 +283,21 @@
[twig-cs-fixer](https://github.com/VincentLanglet/Twig-CS-Fixer) aren't [twig-cs-fixer](https://github.com/VincentLanglet/Twig-CS-Fixer) aren't
packaged for nix. packaged for nix.
- Added `languages.tex`. Currently only highlighting, formatting and lsp. No
previewing yet.
- Added `languages.jq`. Supports highlighting, formatting and lsp.
- Didn't Add - Didn't Add
[`syntax-gaslighting`](https://github.com/NotAShelf/syntax-gaslighting.nvim), [`syntax-gaslighting`](https://github.com/NotAShelf/syntax-gaslighting.nvim),
you're crazy. you're crazy.
- Added neovim theme `gruber-darker`
<https://github.com/blazkowolf/gruber-darker.nvim>.
- Added coverage support (`vim.utility.crazy-coverage`) via
[`crazy-coverage.nvim`](https://github.com/mr-u0b0dy/crazy-coverage.nvim).
[vagahbond](https://github.com/vagahbond): [codewindow.nvim]: [vagahbond](https://github.com/vagahbond): [codewindow.nvim]:
https://github.com/gorbit99/codewindow.nvim https://github.com/gorbit99/codewindow.nvim
@ -294,4 +353,16 @@ https://github.com/gorbit99/codewindow.nvim
- Fix `vim.assistant.codecompanion-nvim` lazy loading with [blink-cmp] - Fix `vim.assistant.codecompanion-nvim` lazy loading with [blink-cmp]
[foobar14](https://github.com/foobar14):
- Fix `vim.formatter.conform-nvim.setupOpts.formatters` type for correct merging
[SmackleFunky](https://github.com/SmackleFunky):
- Updated codecompanion-nvim adapters to allow specifying a model.
[tlvince](https://github.com/tlvince):
- Added configuration option for `foldenable`
<!-- vim: set textwidth=80: --> <!-- vim: set textwidth=80: -->

6
flake.lock generated
View file

@ -74,11 +74,11 @@
}, },
"nixpkgs": { "nixpkgs": {
"locked": { "locked": {
"lastModified": 1771008912, "lastModified": 1774386573,
"narHash": "sha256-gf2AmWVTs8lEq7z/3ZAsgnZDhWIckkb+ZnAo5RzSxJg=", "narHash": "sha256-4hAV26quOxdC6iyG7kYaZcM3VOskcPUrdCQd/nx8obc=",
"owner": "nixos", "owner": "nixos",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "a82ccc39b39b621151d6732718e3e250109076fa", "rev": "46db2e09e1d3f113a13c0d7b81e2f221c63b8ce9",
"type": "github" "type": "github"
}, },
"original": { "original": {

View file

@ -7,13 +7,13 @@
}: }:
rustPlatform.buildRustPackage (finalAttrs: { rustPlatform.buildRustPackage (finalAttrs: {
pname = "blink-cmp"; pname = "blink-cmp";
version = "1.9.1"; version = "1.10.1";
src = fetchFromGitHub { src = fetchFromGitHub {
owner = "Saghen"; owner = "Saghen";
repo = "blink.cmp"; repo = "blink.cmp";
tag = "v${finalAttrs.version}"; tag = "v${finalAttrs.version}";
hash = "sha256-GgodXdWpQoF2z1g1/WvnSpfuhskw0aMcOoyZM5l66q8="; hash = "sha256-y8f+bmPkb3M6DzcUkJMxd2woDLoBYslne7aB8A0ejCk=";
}; };
forceShare = [ forceShare = [
@ -39,18 +39,9 @@ rustPlatform.buildRustPackage (finalAttrs: {
# From the blink.cmp flake # From the blink.cmp flake
buildInputs = lib.optionals stdenv.hostPlatform.isAarch64 [rust-jemalloc-sys]; buildInputs = lib.optionals stdenv.hostPlatform.isAarch64 [rust-jemalloc-sys];
# NOTE: The only change in frizbee 0.7.0 was nixpkgs incompatible rust semantic changes cargoHash = "sha256-3o2n4xwNF9Fc3VlPKf3lnvmN7FVus5jQB8gcXXwz50c=";
# Patch just reverts https://github.com/saghen/blink.cmp/commit/cc824ec85b789a54d05241389993c6ab8c040810
# Taken from Nixpkgs' blink.cmp derivation, available under the MIT license
cargoPatches = [
./patches/0001-pin-frizbee.patch
];
cargoHash = "sha256-Qdt8O7IGj2HySb1jxsv3m33ZxJg96Ckw26oTEEyQjfs=";
env = { env = {
RUSTC_BOOTSTRAP = true;
# Those are the Linker args used by upstream. Without those, the build fails. # Those are the Linker args used by upstream. Without those, the build fails.
# See: # See:
# <https://github.com/saghen/blink.cmp/blob/main/.cargo/config.toml#L1C1-L11C2> # <https://github.com/saghen/blink.cmp/blob/main/.cargo/config.toml#L1C1-L11C2>

View file

@ -6,6 +6,7 @@
pnpmConfigHook, pnpmConfigHook,
fetchPnpmDeps, fetchPnpmDeps,
pins, pins,
writableTmpDirAsHomeHook,
}: let }: let
pin = pins.prettier-plugin-astro; pin = pins.prettier-plugin-astro;
in in
@ -28,6 +29,7 @@ in
nativeBuildInputs = [ nativeBuildInputs = [
nodejs nodejs
writableTmpDirAsHomeHook
(pnpmConfigHook.overrideAttrs { (pnpmConfigHook.overrideAttrs {
propagatedBuildInputs = [pnpm_9]; propagatedBuildInputs = [pnpm_9];
}) })

View file

@ -15,5 +15,5 @@ in
sha256 = pin.hash; sha256 = pin.hash;
}; };
npmDepsHash = "sha256-D+gDdKiIG38jV+M/BqTKf0yYj1KXpbIodtQFdzocpn8="; npmDepsHash = "sha256-XVyLW0XDCvZCZxu8g1fP7fRfeU3Hz81o5FCi/i4BKQw=";
}) })

View file

@ -31,6 +31,7 @@
mkGrammarOption = pkgs: grammar: mkGrammarOption = pkgs: grammar:
mkPackageOption pkgs ["${grammar} treesitter"] { mkPackageOption pkgs ["${grammar} treesitter"] {
default = ["vimPlugins" "nvim-treesitter" "grammarPlugins" grammar]; default = ["vimPlugins" "nvim-treesitter" "grammarPlugins" grammar];
nullable = true;
}; };
in { in {
inherit diagnostics diagnosticSubmodule mkGrammarOption; inherit diagnostics diagnosticSubmodule mkGrammarOption;

View file

@ -342,5 +342,10 @@ in {
Incremental selection configuration has been removed from nvim-treesitter. Incremental selection configuration has been removed from nvim-treesitter.
'') '')
] ]
# 2026-03-19
[
(mkRenamedOptionModule ["vim" "treesitter" "foldByDefault"] ["vim" "options" "foldenable"])
]
]; ];
} }

View file

@ -78,6 +78,11 @@ in {
}; };
}; };
# Alias vim.options as vim.opts.
# This is a convenience for people using frameworks like flake-parts or Den that use lib.types.deferredModule
# and users would set `vim.options` but error when Nix confuses it with Nix Module's options-definitions.
imports = [(lib.mkAliasOptionModule ["vim" "opts"] ["vim" "options"])];
config.vim = { config.vim = {
# Set options that were previously interpolated in 'luaConfigRC.basic' as vim.options (vim.o) # Set options that were previously interpolated in 'luaConfigRC.basic' as vim.options (vim.o)
# and 'vim.globals' (vim.g). Future options, if possible, should be added here instead of the # and 'vim.globals' (vim.g). Future options, if possible, should be added here instead of the

View file

@ -1,6 +1,6 @@
{lib, ...}: let {lib, ...}: let
inherit (lib.options) mkOption mkEnableOption; inherit (lib.options) mkOption mkEnableOption literalExpression;
inherit (lib.types) int str enum nullOr attrs; inherit (lib.types) int str enum nullOr attrs either submodule;
inherit (lib.nvim.types) mkPluginSetupOption luaInline; inherit (lib.nvim.types) mkPluginSetupOption luaInline;
in { in {
options.vim.assistant = { options.vim.assistant = {
@ -202,9 +202,23 @@ in {
strategies = { strategies = {
chat = { chat = {
adapter = mkOption { adapter = mkOption {
type = nullOr str;
default = null; default = null;
description = "Adapter used for the chat strategy."; description = "Adapter used for the chat strategy.";
type = nullOr (either str (submodule {
options = {
name = mkOption {
type = nullOr str;
default = null;
description = "Name of the Adapter";
};
model = mkOption {
type = nullOr str;
default = null;
description = "Model used for Adapter.";
};
};
}));
}; };
keymaps = mkOption { keymaps = mkOption {
@ -253,9 +267,23 @@ in {
inline = { inline = {
adapter = mkOption { adapter = mkOption {
type = nullOr str;
default = null; default = null;
description = "Adapter used for the inline strategy."; description = "Adapter used for the inline strategy.";
type = nullOr (either str (submodule {
options = {
name = mkOption {
type = nullOr str;
default = null;
description = "Name of the Adapter";
};
model = mkOption {
type = nullOr str;
default = null;
description = "Model used for Adapter.";
};
};
}));
}; };
variables = mkOption { variables = mkOption {

View file

@ -1,7 +1,7 @@
{lib, ...}: let {lib, ...}: let
inherit (lib.generators) mkLuaInline; inherit (lib.generators) mkLuaInline;
inherit (lib.options) mkOption mkEnableOption literalMD; inherit (lib.options) mkOption mkEnableOption literalMD;
inherit (lib.types) attrs either nullOr listOf submodule str; inherit (lib.types) attrs attrsOf either nullOr listOf submodule str;
inherit (lib.nvim.lua) toLuaObject; inherit (lib.nvim.lua) toLuaObject;
inherit (lib.nvim.types) luaInline mkPluginSetupOption; inherit (lib.nvim.types) luaInline mkPluginSetupOption;
@ -49,7 +49,7 @@ in {
enable = mkEnableOption "lightweight yet powerful formatter plugin for Neovim [conform-nvim]"; enable = mkEnableOption "lightweight yet powerful formatter plugin for Neovim [conform-nvim]";
setupOpts = mkPluginSetupOption "conform.nvim" { setupOpts = mkPluginSetupOption "conform.nvim" {
formatters = mkOption { formatters = mkOption {
type = formattersType; type = attrsOf formattersType;
default = {}; default = {};
description = "Custom formatters and overrides for built-in formatters."; description = "Custom formatters and overrides for built-in formatters.";
}; };

View file

@ -25,12 +25,14 @@ in {
./html.nix ./html.nix
./tera.nix ./tera.nix
./twig.nix ./twig.nix
./liquid.nix
./haskell.nix ./haskell.nix
./java.nix ./java.nix
./jinja.nix ./jinja.nix
./json.nix ./json.nix
./lua.nix ./lua.nix
./markdown.nix ./markdown.nix
./tex.nix
./nim.nix ./nim.nix
./vala.nix ./vala.nix
./nix.nix ./nix.nix
@ -59,7 +61,10 @@ in {
./just.nix ./just.nix
./make.nix ./make.nix
./xml.nix ./xml.nix
./gettext.nix
./fluent.nix ./fluent.nix
./openscad.nix
./jq.nix
# This is now a hard deprecation. # This is now a hard deprecation.
(mkRenamedOptionModule ["vim" "languages" "enableLSP"] ["vim" "lsp" "enable"]) (mkRenamedOptionModule ["vim" "languages" "enableLSP"] ["vim" "lsp" "enable"])

View file

@ -0,0 +1,35 @@
{
config,
pkgs,
lib,
...
}: let
inherit (lib.modules) mkIf mkMerge;
inherit (lib.nvim.types) mkGrammarOption;
inherit (lib.options) mkEnableOption literalExpression;
cfg = config.vim.languages.gettext;
# TODO: package `msgfmt --check` into nvim-lint
# TODO: package `msgcat` into conform.nvim
in {
options.vim.languages.gettext = {
enable = mkEnableOption "gettext portable object language support";
treesitter = {
enable =
mkEnableOption "gettext portable object language treesitter"
// {
default = config.vim.languages.enableTreesitter;
defaultText = literalExpression "config.vim.languages.enableTreesitter";
};
package = mkGrammarOption pkgs "po";
};
};
config = mkIf cfg.enable (mkMerge [
(mkIf cfg.treesitter.enable {
vim.treesitter.enable = true;
vim.treesitter.grammars = [cfg.treesitter.package];
})
]);
}

View file

@ -8,20 +8,27 @@
inherit (lib.options) mkEnableOption mkOption literalExpression; inherit (lib.options) mkEnableOption mkOption literalExpression;
inherit (lib.meta) getExe; inherit (lib.meta) getExe;
inherit (lib.modules) mkIf mkMerge; inherit (lib.modules) mkIf mkMerge;
inherit (lib.types) bool enum listOf; inherit (lib.types) enum listOf;
inherit (lib.nvim.types) mkGrammarOption deprecatedSingleOrListOf; inherit (lib.nvim.types) mkGrammarOption deprecatedSingleOrListOf;
inherit (lib.nvim.attrsets) mapListToAttrs; inherit (lib.nvim.attrsets) mapListToAttrs;
cfg = config.vim.languages.hcl; cfg = config.vim.languages.hcl;
defaultServers = ["terraform-ls"]; defaultServers = ["tofuls-hcl"];
servers = { servers = {
terraform-ls = { terraformls-hcl = {
enable = true; enable = true;
cmd = [(getExe pkgs.terraform-ls) "serve"]; cmd = [(getExe pkgs.terraform-ls) "serve"];
filetypes = ["terraform" "terraform-vars"]; filetypes = ["hcl"];
root_markers = [".git"];
};
tofuls-hcl = {
enable = true;
cmd = [(getExe pkgs.tofu-ls) "serve"];
filetypes = ["hcl"];
root_markers = [".terraform" ".git"]; root_markers = [".terraform" ".git"];
}; };
# TODO: package nomad-lsp and offer as an option here too
}; };
defaultFormat = ["hclfmt"]; defaultFormat = ["hclfmt"];
@ -29,6 +36,11 @@
hclfmt = { hclfmt = {
command = getExe pkgs.hclfmt; command = getExe pkgs.hclfmt;
}; };
nomad-fmt = {
command = getExe pkgs.nomad;
args = ["fmt" "$FILENAME"];
stdin = false;
};
}; };
in { in {
options.vim.languages.hcl = { options.vim.languages.hcl = {
@ -66,7 +78,7 @@ in {
defaultText = literalExpression "config.vim.languages.enableFormat"; defaultText = literalExpression "config.vim.languages.enableFormat";
}; };
type = mkOption { type = mkOption {
type = deprecatedSingleOrListOf "vim.language.hcl.format.type" (enum (attrNames formats)); type = listOf (enum (attrNames formats));
default = defaultFormat; default = defaultFormat;
description = "HCL formatter to use"; description = "HCL formatter to use";
}; };
@ -97,18 +109,21 @@ in {
} }
''; '';
} }
(mkIf cfg.treesitter.enable { (mkIf cfg.treesitter.enable {
vim.treesitter.enable = true; vim.treesitter.enable = true;
vim.treesitter.grammars = [cfg.treesitter.package]; vim.treesitter.grammars = [cfg.treesitter.package];
}) })
(mkIf cfg.lsp.enable { (mkIf cfg.lsp.enable {
vim.lsp.servers = vim = {
mapListToAttrs (n: { lsp.servers =
name = n; mapListToAttrs (n: {
value = servers.${n}; name = n;
}) value = servers.${n};
cfg.lsp.servers; })
cfg.lsp.servers;
};
}) })
(mkIf cfg.format.enable { (mkIf cfg.format.enable {

View file

@ -0,0 +1,114 @@
{
config,
lib,
pkgs,
...
}: let
inherit (builtins) attrNames;
inherit (lib.options) literalExpression mkEnableOption mkOption;
inherit (lib.modules) mkIf mkMerge;
inherit (lib.meta) getExe;
inherit (lib.types) enum listOf;
inherit (lib.nvim.attrsets) mapListToAttrs;
inherit (lib.nvim.types) mkGrammarOption;
cfg = config.vim.languages.jq;
defaultServers = ["jq-lsp"];
servers = {
jq-lsp = {
enable = true;
cmd = [(getExe pkgs.jq-lsp)];
filetypes = ["jq"];
root_markers = [".git"];
};
};
defaultFormat = ["jqfmt"];
formats = {
jqfmt = {
command = getExe pkgs.jqfmt;
args = [
"-ob"
"-ar"
"-op=pipe"
];
};
};
in {
options.vim.languages.jq = {
enable = mkEnableOption "JQ support";
treesitter = {
enable =
mkEnableOption "JQ treesitter"
// {
default = config.vim.languages.enableTreesitter;
defaultText = literalExpression "config.vim.languages.enableTreesitter";
};
package = mkGrammarOption pkgs "jq";
};
lsp = {
enable =
mkEnableOption "JQ LSP support"
// {
default = config.vim.lsp.enable;
defaultText = literalExpression "config.vim.lsp.enable";
};
servers = mkOption {
type = listOf (enum (attrNames servers));
default = defaultServers;
description = "JQ LSP server to use";
};
};
format = {
enable =
mkEnableOption "JQ formatting"
// {
default = config.vim.languages.enableFormat;
defaultText = literalExpression "config.vim.languages.enableFormat";
};
type = mkOption {
description = "JQ formatter to use";
type = listOf (enum (attrNames formats));
default = defaultFormat;
};
};
};
config = mkIf cfg.enable (mkMerge [
(mkIf cfg.treesitter.enable {
vim.treesitter = {
enable = true;
grammars = [cfg.treesitter.package];
};
})
(mkIf cfg.lsp.enable {
vim.lsp.servers =
mapListToAttrs (n: {
name = n;
value = servers.${n};
})
cfg.lsp.servers;
})
(mkIf cfg.format.enable {
vim.formatter.conform-nvim = {
enable = true;
setupOpts = {
formatters_by_ft.jq = cfg.format.type;
formatters =
mapListToAttrs (name: {
inherit name;
value = formats.${name};
})
cfg.format.type;
};
};
})
]);
}

View file

@ -0,0 +1,34 @@
{
config,
pkgs,
lib,
...
}: let
inherit (lib.options) mkEnableOption literalExpression;
inherit (lib.modules) mkIf mkMerge;
inherit (lib.nvim.types) mkGrammarOption;
cfg = config.vim.languages.liquid;
in {
options.vim.languages.liquid = {
enable = mkEnableOption "Liquid templating language support";
treesitter = {
enable =
mkEnableOption "Liquid treesitter"
// {
default = config.vim.languages.enableTreesitter;
defaultText = literalExpression "config.vim.languages.enableTreesitter";
};
package = mkGrammarOption pkgs "liquid";
};
# TODO: if curlylint gets packaged for nix, add it.
};
config = mkIf cfg.enable (mkMerge [
(mkIf cfg.treesitter.enable {
vim.treesitter.enable = true;
vim.treesitter.grammars = [cfg.treesitter.package];
})
]);
}

View file

@ -21,7 +21,7 @@
marksman = { marksman = {
enable = true; enable = true;
cmd = [(getExe pkgs.marksman) "server"]; cmd = [(getExe pkgs.marksman) "server"];
filetypes = ["markdown" "markdown.mdx"]; filetypes = ["markdown" "mdx"];
root_markers = [".marksman.toml" ".git"]; root_markers = [".marksman.toml" ".git"];
}; };

View file

@ -0,0 +1,62 @@
{
config,
pkgs,
lib,
...
}: let
inherit (builtins) attrNames;
inherit (lib.options) mkEnableOption mkOption literalExpression;
inherit (lib.modules) mkIf mkMerge;
inherit (lib.types) enum listOf;
inherit (lib.meta) getExe;
inherit (lib.nvim.attrsets) mapListToAttrs;
cfg = config.vim.languages.openscad;
/*
There is no Treesitter module for OpenSCAD yet.
Luckily vim already ships with a builtin syntax that is used by default.
The LSP already ships with diagnostics, but there is also an experimental analyzer called sca2d
<https://search.nixos.org/packages?channel=unstable&query=sca2d>
But it isn't packaged for nvim-lint and would need extra work.
*/
defaultServers = ["openscad-lsp"];
servers = {
openscad-lsp = {
enable = true;
cmd = [(getExe pkgs.openscad-lsp) "--stdio"];
filetypes = ["openscad"];
};
};
in {
options.vim.languages.openscad = {
enable = mkEnableOption "OpenSCAD language support";
lsp = {
enable =
mkEnableOption "OpenSCAD LSP support"
// {
default = config.vim.lsp.enable;
defaultText = literalExpression "config.vim.lsp.enable";
};
servers = mkOption {
type = listOf (enum (attrNames servers));
default = defaultServers;
description = "OpenSCAD LSP server to use";
};
};
};
config = mkIf cfg.enable (mkMerge [
(mkIf cfg.lsp.enable {
vim.lsp.servers =
mapListToAttrs (n: {
name = n;
value = servers.${n};
})
cfg.lsp.servers;
})
]);
}

View file

@ -136,7 +136,7 @@ in {
type = attrs; type = attrs;
default = { default = {
type = "executable"; type = "executable";
command = "${pkgs.nodePackages_latest.nodejs}/bin/node"; command = getExe pkgs.nodejs;
args = [ args = [
"${pkgs.vscode-extensions.xdebug.php-debug}/share/vscode/extensions/xdebug.php-debug/out/phpDebug.js" "${pkgs.vscode-extensions.xdebug.php-debug}/share/vscode/extensions/xdebug.php-debug/out/phpDebug.js"
]; ];

View file

@ -9,7 +9,7 @@
inherit (lib.options) mkEnableOption mkOption literalExpression; inherit (lib.options) mkEnableOption mkOption literalExpression;
inherit (lib.modules) mkIf mkMerge; inherit (lib.modules) mkIf mkMerge;
inherit (lib.meta) getExe; inherit (lib.meta) getExe;
inherit (lib.types) enum package coercedTo; inherit (lib.types) enum coercedTo;
inherit (lib.nvim.types) mkGrammarOption diagnostics deprecatedSingleOrListOf; inherit (lib.nvim.types) mkGrammarOption diagnostics deprecatedSingleOrListOf;
inherit (lib.nvim.attrsets) mapListToAttrs; inherit (lib.nvim.attrsets) mapListToAttrs;
inherit (lib.generators) mkLuaInline; inherit (lib.generators) mkLuaInline;
@ -60,7 +60,7 @@
prettierPluginPath = "${prettierPlugin}/lib/node_modules/prettier-plugin-svelte/plugin.js"; prettierPluginPath = "${prettierPlugin}/lib/node_modules/prettier-plugin-svelte/plugin.js";
in { in {
prettier = { prettier = {
command = getExe pkgs.nodePackages.prettier; command = getExe pkgs.prettier;
options.ft_parsers.svelte = "svelte"; options.ft_parsers.svelte = "svelte";
prepend_args = ["--plugin=${prettierPluginPath}"]; prepend_args = ["--plugin=${prettierPluginPath}"];
}; };
@ -130,7 +130,12 @@ in {
}; };
format = { format = {
enable = mkEnableOption "Svelte formatting" // {default = config.vim.languages.enableFormat;}; enable =
mkEnableOption "Svelte formatting"
// {
default = config.vim.languages.enableFormat;
defaultText = literalExpression "config.vim.languages.enableFormat";
};
type = mkOption { type = mkOption {
type = formatType; type = formatType;
@ -140,7 +145,12 @@ in {
}; };
extraDiagnostics = { extraDiagnostics = {
enable = mkEnableOption "extra Svelte diagnostics" // {default = config.vim.languages.enableExtraDiagnostics;}; enable =
mkEnableOption "extra Svelte diagnostics"
// {
default = config.vim.languages.enableExtraDiagnostics;
defaultText = literalExpression "config.vim.languages.enableExtraDiagnostics";
};
types = diagnostics { types = diagnostics {
langDesc = "Svelte"; langDesc = "Svelte";

View file

@ -9,23 +9,43 @@
inherit (lib.modules) mkIf mkMerge; inherit (lib.modules) mkIf mkMerge;
inherit (lib.meta) getExe; inherit (lib.meta) getExe;
inherit (lib.types) enum listOf; inherit (lib.types) enum listOf;
inherit (lib.nvim.types) mkGrammarOption; inherit (lib.nvim.types) mkGrammarOption deprecatedSingleOrListOf;
inherit (lib.nvim.attrsets) mapListToAttrs; inherit (lib.nvim.attrsets) mapListToAttrs;
cfg = config.vim.languages.terraform; cfg = config.vim.languages.terraform;
defaultServers = ["terraformls"]; defaultServers = ["tofuls-tf"];
servers = { servers = {
terraformls = { terraformls-tf = {
enable = true; enable = true;
cmd = [(getExe pkgs.terraform-ls) "serve"]; cmd = [(getExe pkgs.terraform-ls) "serve"];
filetypes = ["terraform" "terraform-vars"]; filetypes = ["terraform" "terraform-vars" "tf"];
root_markers = [".terraform" ".git"]; root_markers = [".terraform" ".git"];
}; };
tofuls-tf = {
enable = true;
cmd = [(getExe pkgs.tofu-ls) "serve"];
filetypes = ["terraform" "terraform-vars" "tf"];
root_markers = [".terraform" ".git"];
};
};
defaultFormat = ["tofu-fmt"];
formats = {
tofu-fmt = {
command = "${getExe pkgs.opentofu}";
args = ["fmt" "$FILENAME"];
stdin = false;
};
terraform-fmt = {
command = "${getExe pkgs.terraform}";
args = ["fmt" "$FILENAME"];
stdin = false;
};
}; };
in { in {
options.vim.languages.terraform = { options.vim.languages.terraform = {
enable = mkEnableOption "Terraform/HCL support"; enable = mkEnableOption "Terraform support";
treesitter = { treesitter = {
enable = enable =
@ -44,14 +64,28 @@ in {
default = config.vim.lsp.enable; default = config.vim.lsp.enable;
defaultText = literalExpression "config.vim.lsp.enable"; defaultText = literalExpression "config.vim.lsp.enable";
}; };
servers = mkOption { servers = mkOption {
type = listOf (enum (attrNames servers)); type = listOf (enum (attrNames servers));
default = defaultServers; default = defaultServers;
description = "Terraform LSP server to use"; description = "Terraform LSP server to use";
}; };
}; };
format = {
enable =
mkEnableOption "Enable Terraform formatting"
// {
default = config.vim.languages.enableFormat;
defaultText = literalExpression "config.vim.languages.enableFormat";
};
type = mkOption {
type = listOf (enum (attrNames formats));
default = defaultFormat;
description = "Terraform formatter to use";
};
};
}; };
config = mkIf cfg.enable (mkMerge [ config = mkIf cfg.enable (mkMerge [
(mkIf cfg.treesitter.enable { (mkIf cfg.treesitter.enable {
vim.treesitter.enable = true; vim.treesitter.enable = true;
@ -59,12 +93,29 @@ in {
}) })
(mkIf cfg.lsp.enable { (mkIf cfg.lsp.enable {
vim.lsp.servers = vim = {
mapListToAttrs (n: { lsp.servers =
name = n; mapListToAttrs (n: {
value = servers.${n}; name = n;
}) value = servers.${n};
cfg.lsp.servers; })
cfg.lsp.servers;
};
})
(mkIf cfg.format.enable {
vim.formatter.conform-nvim = {
enable = true;
setupOpts = {
formatters_by_ft.terraform = cfg.format.type;
formatters =
mapListToAttrs (name: {
inherit name;
value = formats.${name};
})
cfg.format.type;
};
};
}) })
]); ]);
} }

View file

@ -0,0 +1,115 @@
{
config,
pkgs,
lib,
...
}: let
inherit (builtins) attrNames;
inherit (lib.meta) getExe;
inherit (lib.modules) mkIf mkMerge;
inherit (lib.options) literalExpression mkEnableOption mkOption;
inherit (lib.types) bool enum listOf;
inherit (lib.nvim.types) mkGrammarOption;
inherit (lib.nvim.attrsets) mapListToAttrs;
cfg = config.vim.languages.tex;
defaultServers = ["texlab"];
servers = {
texlab = {
enable = true;
cmd = [(getExe pkgs.texlab) "run"];
filetypes = ["plaintex" "tex" "bib"];
root_markers = [".git" ".latexmkrc" "latexmkrc" ".texlabroot" "texlabroot" ".texstudio" "Tectonic.toml"];
};
};
defaultFormat = ["tex-fmt"];
formats = {
tex-fmt = {
command = getExe pkgs.tex-fmt;
};
latexindent = {
command = "${pkgs.texlive.withPackages (ps: [ps.latexindent])}/bin/latexindent";
};
};
in {
options.vim.languages.tex = {
enable = mkEnableOption "TeX language support";
treesitter = {
enable = mkOption {
type = bool;
default = config.vim.languages.enableTreesitter;
defaultText = literalExpression "config.vim.languages.enableTreesitter";
description = "Enable TeX treesitter";
};
latexPackage = mkGrammarOption pkgs "latex";
bibtexPackage = mkGrammarOption pkgs "bibtex";
};
lsp = {
enable =
mkEnableOption "TeX LSP support"
// {
default = config.vim.lsp.enable;
defaultText = literalExpression "config.vim.lsp.enable";
};
servers = mkOption {
description = "TeX LSP server to use";
type = listOf (enum (attrNames servers));
default = defaultServers;
};
};
format = {
enable =
mkEnableOption "TeX formatting"
// {
default = config.vim.languages.enableFormat;
defaultText = literalExpression "config.vim.languages.enableFormat";
};
type = mkOption {
type = listOf (enum (attrNames formats));
default = defaultFormat;
description = "TeX formatter to use";
};
};
};
config = mkIf cfg.enable (mkMerge [
(mkIf cfg.treesitter.enable {
vim.treesitter.enable = true;
vim.treesitter.grammars = [
cfg.treesitter.latexPackage
cfg.treesitter.bibtexPackage
];
})
(mkIf cfg.lsp.enable {
vim.lsp.servers =
mapListToAttrs (n: {
name = n;
value = servers.${n};
})
cfg.lsp.servers;
})
(mkIf cfg.format.enable {
vim.formatter.conform-nvim = {
enable = true;
setupOpts = {
formatters_by_ft.tex = cfg.format.type;
formatters_by_ft.plaintex = cfg.format.type;
formatters =
mapListToAttrs (name: {
inherit name;
value = formats.${name};
})
cfg.format.type;
};
};
})
]);
}

View file

@ -120,6 +120,19 @@
end end
''; '';
}; };
tsgo = {
cmd = [(getExe pkgs.typescript-go) "--lsp" "--stdio"];
filetypes = [
"javascript"
"javascriptreact"
"javascript.jsx"
"typescript"
"typescriptreact"
"typescript.tsx"
];
root_markers = ["tsconfig.json" "jsconfig.json" "package.json" ".git"];
};
}; };
denols_handlers = '' denols_handlers = ''
@ -186,6 +199,14 @@
biome = { biome = {
command = getExe pkgs.biome; command = getExe pkgs.biome;
}; };
biome-check = {
command = getExe pkgs.biome;
};
biome-organize-imports = {
command = getExe pkgs.biome;
};
}; };
# TODO: specify packages # TODO: specify packages
@ -208,6 +229,14 @@
]; ];
}; };
}; };
biomejs = let
pkg = pkgs.biome;
in {
package = pkg;
config = {
cmd = getExe pkg;
};
};
}; };
in { in {
_file = ./ts.nix; _file = ./ts.nix;
@ -321,7 +350,7 @@ in {
# .tsx/.jsx files # .tsx/.jsx files
typescriptreact = cfg.format.type; typescriptreact = cfg.format.type;
}; };
setupOpts.formatters = formatters =
mapListToAttrs (name: { mapListToAttrs (name: {
inherit name; inherit name;
value = formats.${name}; value = formats.${name};

View file

@ -4,9 +4,7 @@
... ...
}: let }: let
inherit (lib.modules) mkIf mkMerge; inherit (lib.modules) mkIf mkMerge;
inherit (lib.nvim.dag) entryAnywhere;
inherit (lib.nvim.binds) pushDownDefault; inherit (lib.nvim.binds) pushDownDefault;
inherit (lib.nvim.lua) toLuaObject;
cfg = config.vim.notes.neorg; cfg = config.vim.notes.neorg;
in { in {
@ -19,17 +17,21 @@ in {
"nvim-nio" "nvim-nio"
"pathlib-nvim" "pathlib-nvim"
"plenary-nvim" "plenary-nvim"
"neorg"
"neorg-telescope" "neorg-telescope"
]; ];
lazy.plugins.neorg = {
package = "neorg";
setupModule = "neorg";
inherit (cfg) setupOpts;
ft = ["norg"];
cmd = ["Neorg"];
};
binds.whichKey.register = pushDownDefault { binds.whichKey.register = pushDownDefault {
"<leader>o" = "+Notes"; "<leader>o" = "+Notes";
}; };
pluginRC.neorg = entryAnywhere ''
require('neorg').setup(${toLuaObject cfg.setupOpts})
'';
}; };
} }

View file

@ -5,22 +5,32 @@
}: let }: let
inherit (lib.modules) mkIf mkMerge; inherit (lib.modules) mkIf mkMerge;
inherit (lib.generators) mkLuaInline; inherit (lib.generators) mkLuaInline;
inherit (lib.nvim.dag) entryAnywhere;
inherit (lib.nvim.lua) toLuaObject;
cfg = config.vim.notes.obsidian; cfg = config.vim.notes.obsidian;
in { in {
config = mkIf cfg.enable { config = mkIf cfg.enable {
vim = { vim = {
startPlugins = [ startPlugins = [
"obsidian-nvim"
"vim-markdown" "vim-markdown"
"tabular" "tabular"
"plenary-nvim"
]; ];
pluginRC.obsidian = entryAnywhere '' lazy.plugins.obsidian-nvim = {
require("obsidian").setup(${toLuaObject cfg.setupOpts}) package = "obsidian-nvim";
''; # NOTE: packaged plugin directory is `obsidian.nvim`; loading by the
# spec key (`obsidian-nvim`) misses and makes `require("obsidian")`
# resolve to a loader function via lzn-auto-require.
# I don't love this, but I can't think of anything better
load = ''
vim.cmd.packadd("obsidian.nvim")
'';
setupModule = "obsidian";
inherit (cfg) setupOpts;
ft = ["markdown"];
cmd = ["Obsidian"];
};
notes.obsidian.setupOpts = let notes.obsidian.setupOpts = let
# may not be defined # may not be defined

View file

@ -14,6 +14,32 @@ in {
}; };
config = mkIf cfg.enable { config = mkIf cfg.enable {
vim.startPlugins = [pkgs.vimPlugins.conjure]; vim.lazy.plugins.conjure = {
package = pkgs.vimPlugins.conjure;
ft = [
"clojure"
"fennel"
"janet"
"hy"
"julia"
"racket"
"scheme"
"lua"
"lisp"
"python"
"rust"
"sql"
"javascript"
"typescript"
"php"
"r"
];
cmd = [
"ConjureSchool"
"ConjureEval"
"ConjureConnect"
"ConjureClientState"
];
};
}; };
} }

View file

@ -37,6 +37,29 @@ in {
''; '';
styles = ["dark" "darker" "cool" "deep" "warm" "warmer"]; styles = ["dark" "darker" "cool" "deep" "warm" "warmer"];
}; };
gruber-darker = {
setup = _: ''
require('gruber-darker').setup({
-- defaults
bold = true,
invert = {
signs = false,
tabline = false,
visual = false,
},
italic = {
strings = true,
comments = true,
operators = false,
folds = true,
},
undercurl = true,
underline = true,
})
vim.cmd('colorscheme gruber-darker')
'';
styles = ["dark"];
};
tokyonight = { tokyonight = {
setup = { setup = {

View file

@ -54,10 +54,6 @@ in {
callback = function() callback = function()
vim.wo[0][0].foldmethod = "expr" vim.wo[0][0].foldmethod = "expr"
vim.wo[0][0].foldexpr = "v:lua.vim.treesitter.foldexpr()" vim.wo[0][0].foldexpr = "v:lua.vim.treesitter.foldexpr()"
-- This is optional, but is set rather as a sane default.
-- If unset, opened files will be folded by automatically as
-- the files are opened
vim.o.foldenable = false
end, end,
}) })
''} ''}

View file

@ -0,0 +1,18 @@
{
config,
lib,
...
}: let
inherit (lib.modules) mkIf;
inherit (lib.nvim.dag) entryAnywhere;
inherit (lib.nvim.lua) toLuaObject;
cfg = config.vim.utility.crazy-coverage;
in {
config = mkIf cfg.enable {
vim.startPlugins = ["crazy-coverage"];
vim.pluginRC.crazy-coverage = entryAnywhere ''
require("crazy-coverage").setup(${toLuaObject cfg.setupOpts})
'';
};
}

View file

@ -0,0 +1,11 @@
{lib, ...}: let
inherit (lib.options) mkEnableOption;
inherit (lib.nvim.types) mkPluginSetupOption;
in {
options.vim.utility.crazy-coverage = {
enable = mkEnableOption "coverage for neovim";
setupOpts =
mkPluginSetupOption "crazy-coverage.nvim" {};
};
}

View file

@ -0,0 +1,6 @@
_: {
imports = [
./crazy-coverage.nix
./config.nix
];
}

View file

@ -30,5 +30,6 @@
./yanky-nvim ./yanky-nvim
./yazi-nvim ./yazi-nvim
./undotree ./undotree
./crazy-coverage
]; ];
} }

View file

@ -11,7 +11,6 @@ in {
vim = { vim = {
startPlugins = [ startPlugins = [
"plenary-nvim" "plenary-nvim"
"fzf-lua"
"nui-nvim" "nui-nvim"
]; ];

View file

@ -24,7 +24,10 @@
); );
# Build a given Treesitter grammar. # Build a given Treesitter grammar.
buildTreesitterPlug = grammars: vimPlugins.nvim-treesitter.withPlugins (_: grammars); buildTreesitterPlug = grammars:
vimPlugins.nvim-treesitter.withPlugins (
_: builtins.filter (g: g != null) grammars
);
pluginBuilders = { pluginBuilders = {
nvim-treesitter = buildTreesitterPlug config.vim.treesitter.grammars; nvim-treesitter = buildTreesitterPlug config.vim.treesitter.grammars;

File diff suppressed because it is too large Load diff