Complete system rework feat. Niri, Noctalia, Helix, Vicinae, Zellij, & Kanshi
This commit is contained in:
@@ -2,17 +2,38 @@
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
let
|
||||
yazi-picker = pkgs.writeShellApplication {
|
||||
name = "yazi-picker";
|
||||
text = ''
|
||||
paths=$(yazi --chooser-file=/dev/stdout)
|
||||
|
||||
if [[ -n "$paths" ]]; then
|
||||
zellij action toggle-floating-panes
|
||||
zellij action write 27 # send <Escape> key
|
||||
zellij action write-chars ":$1 $paths"
|
||||
zellij action write 13 # send <Enter> key
|
||||
else
|
||||
zellij action toggle-floating-panes
|
||||
fi
|
||||
'';
|
||||
};
|
||||
in
|
||||
{
|
||||
home.packages = [ yazi-picker ];
|
||||
|
||||
programs.helix = {
|
||||
enable = true;
|
||||
defaultEditor = true;
|
||||
extraPackages = with pkgs; [
|
||||
basedpyright
|
||||
ruff
|
||||
# pylyzer
|
||||
isort
|
||||
black
|
||||
nixd
|
||||
nixfmt
|
||||
rust-analyzer
|
||||
rustfmt
|
||||
];
|
||||
languages = {
|
||||
language = [
|
||||
@@ -21,7 +42,6 @@
|
||||
language-servers = [
|
||||
"basedpyright"
|
||||
"ruff"
|
||||
# "pylyzer"
|
||||
];
|
||||
auto-format = true;
|
||||
formatter = {
|
||||
@@ -40,6 +60,18 @@
|
||||
command = "nixfmt";
|
||||
};
|
||||
}
|
||||
{
|
||||
name = "rust";
|
||||
language-servers = [ "rust-analyzer" ];
|
||||
auto-format = true;
|
||||
roots = [
|
||||
"Cargo.toml"
|
||||
"Cargo.lock"
|
||||
];
|
||||
formatter = {
|
||||
command = "rustfmt";
|
||||
};
|
||||
}
|
||||
];
|
||||
language-server = {
|
||||
basedpyright.config.python.analysis = {
|
||||
@@ -49,17 +81,29 @@
|
||||
command = "ruff";
|
||||
args = [ "server" ];
|
||||
};
|
||||
# pylyzer = {
|
||||
# command = "pylyzer";
|
||||
# args = [ "--server" ];
|
||||
# };
|
||||
nixd = {
|
||||
command = "nixd";
|
||||
};
|
||||
rust-analyzer = {
|
||||
command = "rust-analyzer";
|
||||
config = {
|
||||
inlayHints = {
|
||||
bindingModeHints.enable = false;
|
||||
closingBraceHints.minLines = 10;
|
||||
closureReturnTypeHints.enable = "with_block";
|
||||
discriminantHints.enable = "fieldless";
|
||||
lifetimeElisionHints.enable = "skip_trivial";
|
||||
typeHints.hideClosureInitialization = false;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
settings = {
|
||||
editor = {
|
||||
bufferline = "always";
|
||||
completion-timeout = 5;
|
||||
completion-trigger-len = 1;
|
||||
line-number = "relative";
|
||||
cursorline = true;
|
||||
color-modes = true;
|
||||
@@ -68,8 +112,22 @@
|
||||
normal = "block";
|
||||
select = "underline";
|
||||
};
|
||||
lsp = {
|
||||
display-inlay-hints = true;
|
||||
};
|
||||
indent-guides = {
|
||||
render = true;
|
||||
skip-levels = 1;
|
||||
};
|
||||
soft-wrap = {
|
||||
enable = true;
|
||||
max-indent-retain = 80;
|
||||
};
|
||||
};
|
||||
keys = {
|
||||
normal = {
|
||||
"C-y" =
|
||||
":sh zellij run -n Yazi -c -f -x 10%% -y 10%% --width 80%% --height 80%% -- yazi-picker open %{buffer_name}";
|
||||
};
|
||||
};
|
||||
theme = "catppuccin_mocha";
|
||||
|
||||
Reference in New Issue
Block a user