Commit Graph
1932 Commits
Author SHA1 Message Date
Austin Horstman 83c2844bec plugins/telescope: migrate helpers -> lib.nixvim 2024-08-22 08:10:31 -05:00
Austin Horstman d7b506efdd plugins/neotest: migrate helpers -> lib.nixvim 2024-08-22 08:04:45 -05:00
Matt Sturgeon 511a328aa3 wrappers: add our lib to the host's _module.args
Make our "extended" lib available to host modules as `_module.args.nixvimLib`.

We didn't do this before because `helpers` was too generic of a name,
but `nixvimLib` should be ok.

    { nixvimLib, ... }: {
        programs.nixvim.someOption = nixvimLib.nixvim.mkRaw "print('Hi')";
    }
2024-08-22 13:19:59 +01:00
Matt Sturgeon e555ba13b1 docs/helpers: document the "extended" lib 2024-08-22 13:19:59 +01:00
github-actions[bot] e41696e502 flake.lock: Update
Flake lock file updates:

• Updated input 'git-hooks':
    'github:cachix/git-hooks.nix/bfef0ada09e2c8ac55bbcd0831bd0c9d42e651ba' (2024-08-16)
  → 'github:cachix/git-hooks.nix/6cedaa7c1b4f82a266e5d30f212273e60d62cb0d' (2024-08-21)
• Updated input 'nix-darwin':
    'github:lnl7/nix-darwin/076b9a905af8a52b866c8db068d6da475839d97b' (2024-08-17)
  → 'github:lnl7/nix-darwin/a8968d88e5a537b0491f68ce910749cd870bdbef' (2024-08-22)
• Updated input 'nixpkgs':
    'github:NixOS/nixpkgs/8a3354191c0d7144db9756a74755672387b702ba' (2024-08-18)
  → 'github:NixOS/nixpkgs/c374d94f1536013ca8e92341b540eba4c22f9c62' (2024-08-21)
2024-08-22 08:02:37 +00:00
Matt Sturgeon b7f419a759 lib: migrate helpers.nixvimTypes -> lib.types 2024-08-21 07:37:11 +01:00
Matt Sturgeon b414a53649 lib/types: merge into extendedLib 2024-08-21 07:37:11 +01:00
Matt Sturgeon 38b09c1621 modules/test: remove docker dependency 2024-08-21 02:48:26 +01:00
Matt Sturgeon 19d5f4b134 lib/test: move from tests/test-derivation 2024-08-21 02:48:06 +01:00
Matt Sturgeon cbd1003d9d modules/test: move test derivation to an option
Introduced the `test.derivation` read-only option.
2024-08-21 02:48:00 +01:00
Matt Sturgeon 851edc8df1 lib/modules: add evalNixvim
Evaluates a nixvim config, by default also checking warnings and assertions.

This used internally by the standalone wrapper.
2024-08-20 22:22:53 +01:00
Matt Sturgeon bc7a7ad1d6 module/outputs: use mkIf for wrapRc
Implement the `wrapRc` option using `lib.mkIf` instead of using _real_
`if` branches.
2024-08-20 22:02:29 +01:00
Matt Sturgeon 6975ee09f5 modules/outputs: make type readOnly at the top-level
Instead of relying on `lib.mkForce` we can enforce this more strictly by
setting the option "readOnly".
2024-08-20 22:02:29 +01:00
Matt Sturgeon c4fcbb0dcf modules/context: add isTopLevel option 2024-08-20 22:02:29 +01:00
Austin Horstman cb413995e1 plugins/todo-comments: migrate keymaps to mkMapOptionSubmodule 2024-08-19 23:18:48 -05:00
Austin Horstman 39081a4106 tests/plugins/lsp: re-enable vala-ls on linux 2024-08-19 20:52:10 -05:00
Austin Horstman 9a218fed31 tests/plugins/none-ls: re-enable d2_fmt and yamlfix 2024-08-19 20:52:10 -05:00
Austin Horstman 366f25598a tests/plugins/lsp: re-enable omnisharp on darwin 2024-08-19 20:52:09 -05:00
Austin Horstman ec9d299183 tests/plugins/openscad: re-enable on darwin
Builds for me locally.
2024-08-19 20:52:09 -05:00
Austin Horstman a1a3488779 tests/plugins/lsp: disable vscode-langservers-extracted tests (broken package)
Re-enable after https://github.com/NixOS/nixpkgs/pull/335559 is
available in nixos-unstable.
2024-08-19 20:52:09 -05:00
Austin Horstman f7cdecbad8 tests/plugins/none-ls: disable prisma_format test (broken package) 2024-08-19 20:52:09 -05:00
Austin Horstman a9ffb6c958 tests/plugins/lsp: disable prismals test (broken package) 2024-08-19 20:52:09 -05:00
Austin Horstman f62d77d3fa plugins/lsp: python3Packages.ruff-lsp -> ruff-lsp fallback 2024-08-19 20:52:09 -05:00
Austin Horstman ec9e5c071a plugins/markview: remove unnecessary extraPlugin 2024-08-19 20:52:09 -05:00
Austin Horstman 94fb980f35 plugins/yazi: remove unnecessary extraPlugin 2024-08-19 20:42:00 -05:00
Gaetan Lepage 460b47997f tests/plugins/lsp: disable typst-lsp test (broken package) 2024-08-19 20:42:00 -05:00
Gaetan Lepage fc6d40d798 tests/plugins/lsp: typst-lsp -> tinymist 2024-08-19 20:42:00 -05:00
Gaetan Lepage b406575176 plugins/lsp/astro: remove unnecessary alternative package path
https://github.com/NixOS/nixpkgs/pull/333736
2024-08-19 20:42:00 -05:00
github-actions[bot] d3cb90aa6e generated: Updated rust-analyzer.nix 2024-08-19 20:42:00 -05:00
github-actions[bot] 907c249aba flake.lock: Update
Flake lock file updates:

• Updated input 'nixpkgs':
    'github:NixOS/nixpkgs/5e0ca22929f3342b19569b21b2f3462f053e497b' (2024-08-09)
  → 'github:NixOS/nixpkgs/a58bc8ad779655e790115244571758e8de055e3d' (2024-08-11)
2024-08-19 20:42:00 -05:00
Matt Sturgeon 123a55ed6f tests: remove special treatment of module
Since we no longer need to extract `tests.dontRun` from an attrset, we
no longer need the "special" `module` attr.
2024-08-20 01:07:21 +01:00
Matt Sturgeon 7b2a6cd9e6 tests: tests.dontRun -> test.runNvim
Convert all test-cases to use the new `test.runNvim` module option.
2024-08-20 00:46:30 +01:00
Matt Sturgeon f47374fd26 modules/test: init, replacing dontRun arg
Introduces the `test.runNvim` module option.

Deprecates the historic `dontRun` argument passed to the test-derivation
helpers.

Soft-deprecates the `tests.dontRun` attr used in tests currently.
2024-08-20 00:34:12 +01:00
Matt Sturgeon 312db6b6e2 flake-modules/devshell: update tests command with link-farm support
Since we're using link-farms, we need to access the underlying tests as
`passthru.entries.*`.
2024-08-19 03:57:22 +01:00
Matt Sturgeon 69c2fa866e tests: group tests by 10
Attempt to find a middle ground between having a single link-farm and
one test per file.

This groups up to ten tests per (roughly) 28 link-farms.
2024-08-19 01:11:10 +01:00
Matt Sturgeon 8f99c3953c lib/util: add groupListBySize
Splits up a list into many sub-lists based on the given max-size.

e.g.
```nix
groupListBySize 2 [ 1 2 3 4 5 ]
=> [ [ 1 2 ] [ 3 4 ] [ 5 ] ]
```
2024-08-19 00:50:57 +01:00
Matt Sturgeon 693e749edb tests/lib-test: correctly print expected/result
In some edge cases, expected and result can't be directly used in string
interpolation, so pass them through `lib.generators.toPretty` to be safe.
2024-08-19 00:38:22 +01:00
Matt Sturgeon 7a11b66f11 lib/keymap: allow extra options/modules in mkMapOptionSubmodule
This is needed to allow plugins to add bespoke features to their keymap
submodules without having to re-implement the whole thing.
2024-08-18 22:38:24 +01:00
Matt Sturgeon 7fb1f9dd9d modules/keymap: improve lua deprecation
- Replace nullable lua option with a no-default option.
- Made it so the deprecated option is only declared when `lua = true` is passed.
- Replace `normalizeMappings` with a `removeDeprecatedMapAttrs` helper.
- Added warnings for all options that historically had `lua` support.
2024-08-18 22:11:11 +01:00
Matt Sturgeon c52ba67856 Revert "tests: Allow to test multiple derivations in a single test derivation"
This reverts commit 71126bfebe.
2024-08-18 20:42:56 +01:00
Matt Sturgeon 9688ef723f tests: use a link-farm again, but only per-file 2024-08-18 20:42:55 +01:00
Austin Horstman 379ae77a76 plugins/todo-comments: migrate to mkNeovimPlugin 2024-08-18 14:25:00 -05:00
Austin Horstman 78fc4be6a8 workflows/update: only run upstream 2024-08-17 14:44:48 -05:00
Austin Horstman 00f32f0430 tests/lua-loader: builtins.match -> lib.hasInfix
Getting invalid regex expression on darwin.
2024-08-16 08:55:38 -05:00
Austin Horstman 6ab17b1b2e top-level/output: include meta in package
Required to prevent errors due to missing license information in
neovim-wrapper.
2024-08-15 22:28:28 -05:00
Austin Horstman ebd2182b44 plugins/which-key: updated spec examples and tests
Improve documentation for supported configurations
2024-08-15 15:47:25 -05:00
Austin Horstman fb4e6c2361 flake-modules/devshell: add getopt runtimeInput
Use a consistent behavior of getopt in launchtests.sh. Wasn't able to
use tests command on macbook without including this because the macOS
getopt didn't support our usage.
2024-08-15 08:02:57 -05:00
Enno Richter a96aa9730a tests/plugins/utils/spectre: enable tests on Darwin 2024-08-14 23:18:51 +02:00
Austin Horstman cb398ce4ba plugins/bufferline: migrate to mkNeovimPlugin
Also resolves https://github.com/nix-community/nixvim/issues/1890 by
automatically setting up `diagnostics.update_in_insert` for the user.
2024-08-14 11:20:17 +00:00
Austin Horstman db4c4e5b17 lib/deprecation: expose mkSettingsRenamedOptionModules publicly
Extracted the `optionsRenamedToSettings` implementation
from`mkVimPlugin` and `mkNeovimPlugin` into a new public helper.
2024-08-14 11:20:17 +00:00