Commit graph

951 commits

Author SHA1 Message Date
Stanislav Asunkin
5c75cfac13 plugins/telescope/fzy-native: add compatibility with combinePlugins 2024-07-24 16:50:50 +02:00
Stanislav Asunkin
61caa52fc5 plugins/telescope/fzf-native: add compatibility with combinePlugins 2024-07-24 16:50:50 +02:00
Stanislav Asunkin
ce93f1724f plugins/treesitter: add workaround for performance.combinePlugins 2024-07-24 16:50:50 +02:00
Stanislav Asunkin
0c32f5bda5 modules/performance: don't combine filesPlugin into plugin pack
It's expected that user may want to override some runtime files in its
own config directory. Do not combine it into plugin pack to avoid
collisions.
2024-07-24 16:50:50 +02:00
Stanislav Asunkin
e65c9590d0 modules/performance: add combinePlugins.standalonePlugins option 2024-07-24 16:50:50 +02:00
Stanislav Asunkin
d6bebcefa3 modules/performance: handle plugin configs when combining plugins 2024-07-24 16:50:50 +02:00
Stanislav Asunkin
27201addd7 modules/performance: handle optional plugins when combining plugins 2024-07-24 16:50:50 +02:00
Stanislav Asunkin
f900dcd6aa modules/performance: handle python3 dependencies when combining plugins 2024-07-24 16:50:50 +02:00
Stanislav Asunkin
fdb3950c59 modules/performance: add an option to combine plugins to a single plugin pack 2024-07-24 16:50:50 +02:00
Nathan Felber
6387299364
plugins/cmake-tools: init 2024-07-24 10:15:51 +01:00
Antonín Říha
ab67ee7e8b plugins/lsp/openscad-lsp: init
Signed-off-by: Antonín Říha <antonin.riha@protonmail.com>
2024-07-24 00:04:05 +02:00
Gaetan Lepage
3b6d403f39 plugins/better-escape: switch to mkNeovimPlugin + update 2024-07-23 23:21:01 +02:00
Stanislav Asunkin
299d0406bb modules/output: refactor config generation
The motivation for this change was to avoid generating empty
config sections like

    vim.cmd([[

    ]])

To make a config generation cleaner several helper functions introduced:

* `hasContent` have been moved to helpers
* `concatNonEmptyLines` joins strings (which has content) separated with
  newlines
* `wrapVimscriptForLua` wraps a lua string for using in Vimscript, but
  only if the string has content, otherwise empty string is returned
* `wrapLuaForVimscript` wraps Vimscript for using in lua, but only if
  the string has content, otherwise empty string is returned

Added tests:

* testing that all possible config sections are present in the final
  generated config
* testing that the config files generated by empty `files` definitions
  don't have any content in it
2024-07-22 23:18:53 +02:00
Matt Sturgeon
6dc0bda459
lib/to-lua: handle derivations as path strings
Fixes #1888
2024-07-22 13:24:16 +01:00
Stanislav Asunkin
34aa3e00e7 modules/filetype: ensure that the module does not set empty settings
When setting any filetype suboption to null (or anything else guarded by
mkIf) it's value becomes:

    { extension = null; filename = null; pattern = null; }

Account for that case in mkIf condition so that the option would not
produce empty filetype definition.
2024-07-22 11:33:52 +03:00
Stanislav Asunkin
06261fc472 modules/lsp/servers/vls: do not add filetype extension if not enabled 2024-07-21 20:17:03 +02:00
Stanislav Asunkin
8eb5763bbb modules/lua-loader: make enable option nullable
This avoids having the option always "defined".

This also avoids luaLoader configuration in extra files by default.
Earlier `vim.loader.disable()` was always added to configs produced
by `files` option, effectively disabling luaLoader even if it was
explicitly enabled in a top-level configuration.
2024-07-21 17:11:50 +03:00
traxys
7908729711 dev: Make the tests command able to select which test to launch
The `tests` command can either launch all tests (without any arguments),
a specific test with `-t/--test` or choose a test with `-i/--interactive`
2024-07-21 15:17:17 +02:00
traxys
b1576362a7 tests: Remove the test link farm
Fixes #1878
2024-07-21 15:17:17 +02:00
Stanislav Asunkin
c9a6912be5 modules/files: fix creating configs of vim type 2024-07-19 14:45:34 +03:00
traxys
daa94bd6c2 tests: Disable coq-nvim defaults on x86_64 darwin 2024-07-19 11:11:17 +02:00
traxys
50d865275d tests: Reduce the number of calls to mkTestDerivationFromNixvimModule 2024-07-19 11:11:17 +02:00
traxys
71126bfebe tests: Allow to test multiple derivations in a single test derivation 2024-07-19 11:11:17 +02:00
Gaetan Lepage
94bea519de tests/efmls-configs: update test excludes 2024-07-14 00:06:08 +02:00
Gaetan Lepage
0d95fc6888 plugins/telescope/extensions/undo: deprecate option diff_context_lines 2024-07-14 00:05:32 +02:00
Matt Sturgeon
d8f3113e90
plugins/none-ls: refactor using mkSourcePlugin
Introduce `_mk-source-plugin.nix`, which returns a module handling a
specific none-ls source plugin.

This wasn't possible previously due to IFD conflicting with evaluating
module imports.

Adjusted the test to use the `options` provided via module args, and
cleaned up some stuff allowing "unpackaged" sources to not be listed
again in the test file.
2024-07-13 20:11:09 +01:00
Austin Horstman
1385953299
plugins/treesitter: fix parser_install_dir default
The plugin's default is not compatible with nix, because it ends up in
the read-only /nix/store.

Set our default to the one used in their upcoming "1.0" version.
2024-07-12 10:48:21 -05:00
Austin Horstman
dc1559f25e
plugins/rustaceanvim: fix deprecation in test 2024-07-12 09:59:09 -05:00
traxys
123c102a13 plugin/rustaceanvim: Handle rust-analyzer settings rename 2024-07-10 22:44:58 +02:00
Matt Sturgeon
34c3c026b4
tests: add check for nixpkgs maintainers
The test fails if a nixvim maintainer is also a nixpkgs maintainer.
2024-07-10 09:18:18 +01:00
Matt Sturgeon
a5e9dbdef1
plugins/bufdelete: init 2024-07-09 14:15:38 +01:00
seth
0f76a8cdfc plugins/glow: init 2024-07-09 06:06:29 +00:00
Austin Horstman
435ef287ab
plugins/treesitter: switch to mkNeovimPlugin 2024-07-08 09:09:48 -05:00
Matt Sturgeon
c0ea106b4b
colorschemes/base16: add settings + refactor
Added support for the plugin's "advanced" config settings.

Removed the enum restriction and prefix concatenation, allowing anything
to be passed through, including raw lua: fixes #1675

The theme list is now much shorter and is included directly in the option
description.

Some general cleanup, in particular to `extraConfig` and `customColorschemeType`.
2024-07-08 10:21:27 +01:00
Gaetan Lepage
451beb4eca plugins/leap: allow __empty for safeLabels option 2024-07-08 09:54:47 +02:00
Matt Sturgeon
f11f991e09
flake/checks: test extraFiles are in the build 2024-07-07 16:43:06 +01:00
Matt Sturgeon
086873bed9
modules: refactor extraFiles
Moved `extraFiles` from `modules/output.nix` into its own file `modules/files.nix`.

Users should now assign text to a `text` attribute, however they could
also assign a file path to a `source` attribute instead.

The old method of directly assigning a string still works, and is
coerced to the new type along with a deprecation warning.
2024-07-07 16:42:47 +01:00
Stanislav Asunkin
6674dea840 modules/output: fix extraLuaPackages 2024-07-06 20:44:43 +00:00
Matt Sturgeon
b59fa976d0
plugins/nvim-osc52: hide warnings in tests 2024-07-05 16:06:01 +01:00
m1mir
87c7757a5b
plugins/coverage: Added keymap for the loadLcov command. 2024-07-05 13:36:29 +01:00
Gaetan Lepage
92e9f5466d plugins/chatgpt: init 2024-07-04 21:00:56 +00:00
Matt Sturgeon
9b25eaaa6f
lib/to-lua: fix removing empties nested in lists
- Add options for removing empty/null list entries (default false)
- Fix recursion into attrs that are themselves list entries

Fixes #1804
2024-07-03 16:44:30 +01:00
Gaetan Lepage
6252a41fc6 plugins/preview: init 2024-07-02 15:38:28 +02:00
Gaetan Lepage
18bea9bad6 plugins/markdown-preview: move source in dedicated markdown sub-folder 2024-07-02 15:33:00 +02:00
Matt Sturgeon
55fee7051f
standalone: rename nixvimExtend to extend
This is our scope, so there's no need to be explicit.

This also follows the precedent set by `lib.extend`, although that takes
an overlay function.
2024-07-01 15:54:29 +01:00
Gaetan Lepage
3bfe71f1ae plugins/yanky: export 'utils' and 'mapping' for more readible settings 2024-07-01 14:22:27 +00:00
Gaetan Lepage
b3c520d13e plugins/yanky: switch to mkNeovimPlugin 2024-07-01 14:22:27 +00:00
Gaetan Lepage
f6e32ac3cf plugins/neoclip: init 2024-07-01 15:37:23 +02:00
Matt Sturgeon
aaab869d4f plugins/flash: switch to mkNeovimPlugin 2024-07-01 12:18:56 +00:00
Matt Sturgeon
3a8d4fee35
plugins/cmp: refactor source->plugin association
Introduce the internal option `cmpSourcePlugins` where plugins can
register their nvim-cmp source name association.
2024-06-30 18:22:59 +01:00