1
0
Fork 0
mirror of https://github.com/nix-community/home-manager synced 2024-09-27 16:57:29 +02:00

neovim: deprecate programs.neovim.configure (#1810)

The `configure` option is not type checked and an artifact of how
nixpkgs is implemented.
We now have the equivalent options in home-manager and managing
interactions between the 2 systems complexifies maintainance of the
module.
Please use the other options at your disposal:
configure.packages.*.opt  -> programs.neovim.plugins = [ { plugin = ...; optional = true; }]
configure.packages.*.start  -> programs.neovim.plugins = [ { plugin = ...; }]
configure.customRC -> programs.neovim.extraConfig
This commit is contained in:
Matthieu Coudron 2021-02-19 09:52:46 +01:00 committed by GitHub
parent 2e795f3efd
commit 55030c8302
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 20 additions and 5 deletions

View file

@ -101,6 +101,16 @@ https://github.com/jonls/redshift/blob/master/redshift.conf.sample[redshift.conf
https://gitlab.com/chinstrap/gammastep/-/blob/master/gammastep.conf.sample[gammastep.conf.sample]
for the available additional options in each program.
* The `programs.neovim.configure` is deprecated in favor of other `programs.neovim` options;
please use the other options at your disposal:
+
[source,nix]
----
configure.packages.*.opt -> programs.neovim.plugins = [ { plugin = ...; optional = true; }]
configure.packages.*.start -> programs.neovim.plugins = [ { plugin = ...; }]
configure.customRC -> programs.neovim.extraConfig
----
[[sec-release-21.05-state-version-changes]]
=== State Version Changes

View file

@ -183,6 +183,8 @@ in {
};
'';
description = ''
Deprecated. Please use the other options.
Generate your init file from your list of plugins and custom commands,
and loads it from the store via <command>nvim -u /nix/store/hash-vimrc</command>
@ -250,11 +252,14 @@ in {
};
in mkIf cfg.enable {
assertions = [{
assertion = cfg.configure == { } || moduleConfigure == { };
message = "The programs.neovim option configure is mutually exclusive"
+ " with extraConfig and plugins.";
}];
warnings = optional (cfg.configure != { }) ''
programs.neovim.configure is deprecated.
Other programs.neovim options can override its settings or ignore them.
Please use the other options at your disposal:
configure.packages.*.opt -> programs.neovim.plugins = [ { plugin = ...; optional = true; }]
configure.packages.*.start -> programs.neovim.plugins = [ { plugin = ...; }]
configure.customRC -> programs.neovim.extraConfig
'';
home.packages = [ cfg.finalPackage ];