mirror of
https://github.com/nix-community/nixvim.git
synced 2025-06-21 08:35:43 +02:00
plugins/deprecation: add rust-tools
This commit is contained in:
parent
876ca32451
commit
029eafd70d
2 changed files with 33 additions and 12 deletions
|
@ -1,5 +1,12 @@
|
||||||
{ lib, ... }:
|
{ lib, ... }:
|
||||||
let
|
let
|
||||||
|
deprecated = {
|
||||||
|
# TODO: added 10-23-2024, move to removed after 24.11
|
||||||
|
"rust-tools" = ''
|
||||||
|
The `rust-tools` project has been abandoned.
|
||||||
|
It is recommended to use `rustaceanvim` instead.
|
||||||
|
'';
|
||||||
|
};
|
||||||
removed = {
|
removed = {
|
||||||
# Added 2023-08-29
|
# Added 2023-08-29
|
||||||
treesitter-playground = ''
|
treesitter-playground = ''
|
||||||
|
@ -64,13 +71,13 @@ in
|
||||||
Please use `plugins.web-devicons` or `plugins.mini.modules.icons` with `plugins.mini.mockDevIcons` instead.
|
Please use `plugins.web-devicons` or `plugins.mini.modules.icons` with `plugins.mini.mockDevIcons` instead.
|
||||||
''
|
''
|
||||||
) iconsPackagePlugins
|
) iconsPackagePlugins
|
||||||
# Show a warning when web-devicons is auto-enabled
|
|
||||||
++ [
|
++ [
|
||||||
(
|
(
|
||||||
{ config, options, ... }:
|
{ config, options, ... }:
|
||||||
{
|
{
|
||||||
config = lib.mkIf (options.plugins.web-devicons.enable.highestPrio == 1490) {
|
config = {
|
||||||
warnings = [
|
warnings =
|
||||||
|
lib.optionals (options.plugins.web-devicons.enable.highestPrio == 1490) [
|
||||||
''
|
''
|
||||||
Nixvim: `plugins.web-devicons` was enabled automatically because the following plugins are enabled.
|
Nixvim: `plugins.web-devicons` was enabled automatically because the following plugins are enabled.
|
||||||
This behaviour is deprecated. Please explicitly define `plugins.web-devicons.enable` or alternatively
|
This behaviour is deprecated. Please explicitly define `plugins.web-devicons.enable` or alternatively
|
||||||
|
@ -79,7 +86,15 @@ in
|
||||||
builtins.filter (name: config.plugins.${name}.enable) iconsPackagePlugins
|
builtins.filter (name: config.plugins.${name}.enable) iconsPackagePlugins
|
||||||
)}
|
)}
|
||||||
''
|
''
|
||||||
];
|
]
|
||||||
|
++ lib.foldlAttrs (
|
||||||
|
warnings: plugin: msg:
|
||||||
|
warnings
|
||||||
|
++ lib.optional config.plugins.${plugin}.enable ''
|
||||||
|
Nixvim Warning: The `${plugin}` plugin has been deprecated.
|
||||||
|
${msg}
|
||||||
|
''
|
||||||
|
) [ ] deprecated;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
|
|
|
@ -1,9 +1,13 @@
|
||||||
{
|
{
|
||||||
empty = {
|
empty = {
|
||||||
|
# Plugin deprecated
|
||||||
|
test.checkWarnings = false;
|
||||||
plugins.rust-tools.enable = true;
|
plugins.rust-tools.enable = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
defaults = {
|
defaults = {
|
||||||
|
# Plugin deprecated
|
||||||
|
test.checkWarnings = false;
|
||||||
plugins.rust-tools = {
|
plugins.rust-tools = {
|
||||||
enable = true;
|
enable = true;
|
||||||
executor = "termopen";
|
executor = "termopen";
|
||||||
|
@ -73,6 +77,8 @@
|
||||||
};
|
};
|
||||||
|
|
||||||
rust-analyzer-options = {
|
rust-analyzer-options = {
|
||||||
|
# Plugin deprecated
|
||||||
|
test.checkWarnings = false;
|
||||||
plugins.rust-tools = {
|
plugins.rust-tools = {
|
||||||
enable = true;
|
enable = true;
|
||||||
server = {
|
server = {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue