aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZhongheng Liu <z.liu@outlook.com.gr>2025-01-14 23:25:03 +0200
committerZhongheng Liu <z.liu@outlook.com.gr>2025-01-14 23:25:03 +0200
commitef09316160f5ad293bf3b42d0e0aa1ad58ba0a0c (patch)
treeba7f6f3cb96847cf698d0e14aaf7a31a3667f568
parent1a57d0a1968da94fc0b38c940bb45255b70abb8d (diff)
downloadnixos-configuration-ef09316160f5ad293bf3b42d0e0aa1ad58ba0a0c.tar.gz
nixos-configuration-ef09316160f5ad293bf3b42d0e0aa1ad58ba0a0c.tar.bz2
nixos-configuration-ef09316160f5ad293bf3b42d0e0aa1ad58ba0a0c.zip
feat(nixvim): tagbar wrapping and lsp
diag: changed to trouble from lsp-lines tagbar: added to see outline of programs wrapping: added
-rw-r--r--home-manager/stvnliu/nixvim/default.nix11
-rw-r--r--home-manager/stvnliu/nixvim/lsp.nix17
-rw-r--r--home-manager/stvnliu/nixvim/tagbar.nix21
-rw-r--r--home-manager/stvnliu/nixvim/treesitter.nix6
-rw-r--r--home-manager/stvnliu/nixvim/wrapping.nix6
5 files changed, 50 insertions, 11 deletions
diff --git a/home-manager/stvnliu/nixvim/default.nix b/home-manager/stvnliu/nixvim/default.nix
index f0b61e4..daeea20 100644
--- a/home-manager/stvnliu/nixvim/default.nix
+++ b/home-manager/stvnliu/nixvim/default.nix
@@ -21,12 +21,23 @@
./wilder.nix
./virt-column.nix
./devicons.nix
+ ./tagbar.nix
+ ./wrapping.nix
];
enable = true;
enableMan = true;
defaultEditor = true;
globals.mapleader = " ";
colorschemes.gruvbox = { enable = true; };
+ performance = {
+ byteCompileLua.enable = true;
+ combinePlugins = {
+ enable = true;
+ /*standalonePlugins = [
+ "nvim-treesitter"
+ ];*/
+ };
+ };
keymaps =
[
# Global
diff --git a/home-manager/stvnliu/nixvim/lsp.nix b/home-manager/stvnliu/nixvim/lsp.nix
index 201aab1..637fbf7 100644
--- a/home-manager/stvnliu/nixvim/lsp.nix
+++ b/home-manager/stvnliu/nixvim/lsp.nix
@@ -11,6 +11,11 @@
#ruff.enable = true;
#ruff_lsp.enable = true;
+ rust-analyzer = {
+ enable = true;
+ installCargo = false;
+ installRustc = false;
+ };
# For CXX
clangd.enable = true;
@@ -19,7 +24,7 @@
fsautocomplete.enable = true;
gopls.enable = true;
- nushell.enable = true;
+ #nushell.enable = true;
# For Nix
#nil_ls.enable = true;
@@ -50,12 +55,12 @@
"K" = "hover";
};
};
- lsp-lines.enable = true;
+ #lsp-lines.enable = true;
- rustaceanvim = {
- enable = true;
- # rust-tools.enable = true;
- };
+ #rustaceanvim = {
+ # enable = true;
+ # # rust-tools.enable = true;
+ #};
};
diagnostics.virtual_lines.only_current_line = true;
}
diff --git a/home-manager/stvnliu/nixvim/tagbar.nix b/home-manager/stvnliu/nixvim/tagbar.nix
new file mode 100644
index 0000000..e011bf7
--- /dev/null
+++ b/home-manager/stvnliu/nixvim/tagbar.nix
@@ -0,0 +1,21 @@
+{ pkgs, ... }:
+
+{
+ plugins.tagbar = {
+ enable = true;
+ tagsPackage = pkgs.universal-ctags;
+ settings = {
+ autoclose = false;
+ autofocus = false;
+ autoshowtag = true;
+ foldlevel = 2;
+ iconchars = [ "" "" ];
+ position = "right";
+ visibility_symbols = {
+ private = "󰛑 ";
+ protected = "󱗤 ";
+ public = "󰡭 ";
+ };
+ };
+ };
+}
diff --git a/home-manager/stvnliu/nixvim/treesitter.nix b/home-manager/stvnliu/nixvim/treesitter.nix
index 9105918..d101cb7 100644
--- a/home-manager/stvnliu/nixvim/treesitter.nix
+++ b/home-manager/stvnliu/nixvim/treesitter.nix
@@ -5,11 +5,7 @@
nixGrammars = true;
nixvimInjections = true; # enables language injection in nixvim
settings.indent.enable = true;
- grammarPackages =
- pkgs.vimPlugins.nvim-treesitter.passthru.allGrammars
- ++ [
- pkgs.tree-sitter-grammars.tree-sitter-nu
- ];
+ grammarPackages = pkgs.vimPlugins.nvim-treesitter.passthru.allGrammars;
};
treesitter-context.enable = true;
rainbow-delimiters.enable = true;
diff --git a/home-manager/stvnliu/nixvim/wrapping.nix b/home-manager/stvnliu/nixvim/wrapping.nix
new file mode 100644
index 0000000..2648e62
--- /dev/null
+++ b/home-manager/stvnliu/nixvim/wrapping.nix
@@ -0,0 +1,6 @@
+{ ... }:
+{
+ plugins.wrapping = {
+ enable = true;
+ };
+}