Compare commits

...

6 Commits

Author SHA1 Message Date
a4e5add644 desktop/niri: tweak copyq
Signed-off-by: unexplrd <unexplrd@linerds.us>
2025-06-14 17:26:23 +03:00
cc31b858f7 desktop/niri: use autoLogin module for greetd
Signed-off-by: unexplrd <unexplrd@linerds.us>
2025-06-14 17:26:23 +03:00
e669331366 config/boot/loader: set timeout to 0
Signed-off-by: unexplrd <unexplrd@linerds.us>
2025-06-14 17:26:23 +03:00
453fda9a36 desktop/niri: disable animations
Signed-off-by: unexplrd <unexplrd@linerds.us>
2025-06-14 17:26:23 +03:00
e2f6ed72ed modules/home/programs/editor: some lsp work
Signed-off-by: unexplrd <unexplrd@linerds.us>
2025-06-14 17:26:23 +03:00
8a4af44494 user/programs: enable zellij
Signed-off-by: unexplrd <unexplrd@linerds.us>
2025-06-14 17:26:23 +03:00
7 changed files with 142 additions and 87 deletions

View File

@ -58,6 +58,7 @@ in {
ripgrep.enable = true; # grep in rust ripgrep.enable = true; # grep in rust
zk.enable = true; zk.enable = true;
zoxide.enable = true; # fuzzy cd in rust zoxide.enable = true; # fuzzy cd in rust
zellij.enable = true;
}; };
home.packages = with pkgs; home.packages = with pkgs;

View File

@ -19,7 +19,6 @@
hostName = "morphius"; hostName = "morphius";
}; };
boot.loader.timeout = lib.mkForce 0;
environment.memoryAllocator.provider = "mimalloc"; environment.memoryAllocator.provider = "mimalloc";
system.stateVersion = "25.11"; system.stateVersion = "25.11";
time.timeZone = "Europe/Kyiv"; time.timeZone = "Europe/Kyiv";

View File

@ -171,8 +171,8 @@ in {
} }
background-color "transparent" background-color "transparent"
// default-column-width { proportion 0.9; } default-column-width { proportion 1.0; }
default-column-width { proportion 0.5; } // default-column-width { proportion 0.5; }
tab-indicator { tab-indicator {
active-color "#${colors.base04}" active-color "#${colors.base04}"
inactive-color "#${colors.base03}" inactive-color "#${colors.base03}"
@ -247,7 +247,8 @@ in {
screenshot-path "${xdgPics}/screenshots/screenshot-%Y-%m-%d-%H-%M-%S.png" screenshot-path "${xdgPics}/screenshots/screenshot-%Y-%m-%d-%H-%M-%S.png"
animations { animations {
slowdown 0.8 // slowdown 0.8
off
} }
window-rule { window-rule {
@ -262,6 +263,7 @@ in {
} }
window-rule { window-rule {
match app-id="re.sonny.Junction" match app-id="re.sonny.Junction"
match app-id="com.github.hluk.copyq"
open-floating true open-floating true
open-focused true open-focused true
} }
@ -319,7 +321,7 @@ in {
Mod+BackSpace repeat=false { spawn "${launcher}"; } Mod+BackSpace repeat=false { spawn "${launcher}"; }
Mod+A repeat=false { spawn "${launcher}"; } Mod+A repeat=false { spawn "${launcher}"; }
Mod+Ctrl+L repeat=false { spawn "${lockscreen}"; } Mod+Ctrl+L repeat=false { spawn "${lockscreen}"; }
Mod+Ctrl+V repeat=false { spawn "copyq" "toggle"; } Mod+Ctrl+V repeat=false { spawn "copyq" "menu"; }
Mod+Shift+W repeat=false { spawn "walker" "-m" "windows"; } Mod+Shift+W repeat=false { spawn "walker" "-m" "windows"; }

View File

@ -62,44 +62,57 @@ in {
}; };
languages = { languages = {
language-server = { language-server = {
clangd.command = "${pkgs.clang-tools}/bin/clangd";
# markdown-oxide.command = getExe pkgs.markdown-oxide; # markdown-oxide.command = getExe pkgs.markdown-oxide;
nil.command = getExe pkgs.nil;
# nixd.command = getExe pkgs.nixd; # nixd.command = getExe pkgs.nixd;
# pyright.command = getExe pkgs.pyright; # pyright = {
# pyright.args = ["-"]; # command = getExe pkgs.pyright;
ruff.command = getExe pkgs.ruff; # args = ["-"];
ruff.args = ["server"]; # };
# rust-analyzer.command = getExe pkgs.rust-analyzer; # rust-analyzer.command = getExe pkgs.rust-analyzer;
# texlab.command = getExe pkgs.texlab; # texlab.command = getExe pkgs.texlab;
bash-language-server = {
command = getExe pkgs.bash-language-server;
environment = {
"SHELLCHECK_PATH" = getExe pkgs.shellcheck;
"SHFMT_PATH" = getExe pkgs.shfmt;
};
};
clangd.command = "${pkgs.clang-tools}/bin/clangd";
fsac = {
command = getExe pkgs.fsautocomplete;
config = {
# editor.formatOnSave = true;
AutomaticWorkspaceInit = true;
FSharp.ExternalAutocomplete = true;
FSharp.linting.fsharplint.enabled = true;
FSharp.linting.fsharplint.configFile = "fsharplint.json";
FSharp.formatting.fantomas.enabled = true;
};
};
nil = {
command = getExe pkgs.nil;
config = {
formatting.command = [(getExe pkgs.alejandra)];
};
};
ruff = {
command = getExe pkgs.ruff;
args = ["server"];
};
tinymist.command = getExe pkgs.tinymist; tinymist.command = getExe pkgs.tinymist;
vscode-json-language-server.command = getExe pkgs.nodePackages.vscode-json-languageserver;
yaml-language-server.command = getExe pkgs.yaml-language-server;
zk = { zk = {
command = getExe pkgs.zk; command = getExe pkgs.zk;
args = ["lsp"]; args = ["lsp"];
}; };
fsac.command = getExe pkgs.fsautocomplete;
fsac.config = {
# editor.formatOnSave = true;
AutomaticWorkspaceInit = true;
FSharp.ExternalAutocomplete = true;
FSharp.linting.fsharplint.enabled = true;
FSharp.linting.fsharplint.configFile = "fsharplint.json";
FSharp.formatting.fantomas.enabled = true;
};
}; };
language = [ language = [
{ {
name = "nix"; name = "nix";
auto-format = true; auto-format = true;
formatter.command = getExe pkgs.alejandra;
language-servers = ["nil"]; language-servers = ["nil"];
} }
# {
# name = "latex";
# auto-format = true;
# formatter.command = "${pkgs.texlivePackages.latexindent}/bin/latexindent";
# language-servers = ["texlab"];
# }
{ {
name = "typst"; name = "typst";
auto-format = true; auto-format = true;
@ -109,23 +122,21 @@ in {
{ {
name = "markdown"; name = "markdown";
# auto-format = true; # auto-format = true;
# formatter.command = "${pkgs.comrak}/bin/comrak";
language-servers = ["zk" "markdown-oxide"]; language-servers = ["zk" "markdown-oxide"];
} }
{ {
name = "c"; name = "c";
auto-format = true; auto-format = true;
formatter.command = "${pkgs.clang-tools}/bin/clang-format"; # formatter.command = "${pkgs.clang-tools}/bin/clang-format";
} }
{ {
name = "cpp"; name = "cpp";
auto-format = true; auto-format = true;
formatter.command = "${pkgs.clang-tools}/bin/clang-format"; # formatter.command = "${pkgs.clang-tools}/bin/clang-format";
} }
{ {
name = "fsharp"; name = "fsharp";
auto-format = true; auto-format = true;
# formatter.command = getExe pkgs.fantomas;
language-servers = ["fsac"]; language-servers = ["fsac"];
scope = "source.fs"; scope = "source.fs";
roots = ["fsproj" "sln" ".git"]; roots = ["fsproj" "sln" ".git"];
@ -136,6 +147,25 @@ in {
# language-servers = ["rust-analyzer"]; # language-servers = ["rust-analyzer"];
# formatter.command = getExe pkgs.rustfmt; # formatter.command = getExe pkgs.rustfmt;
# } # }
{
name = "json";
auto-format = true;
formatter.command = getExe pkgs.jq;
language-servers = ["vscode-json-language-server"];
}
{
name = "yaml";
auto-format = true;
formatter.command = getExe pkgs.yamlfmt;
formatter.args = ["-"];
language-servers = ["yaml-language-server"];
}
{
name = "bash";
auto-format = true;
# formatter.command = getExe pkgs.shfmt;
# formatter.args = ["-"];
}
{ {
name = "python"; name = "python";
auto-format = true; auto-format = true;

View File

@ -15,11 +15,11 @@ in {
programs.zed-editor = { programs.zed-editor = {
enable = true; enable = true;
extensions = [ extensions = [
"nix" "bash"
"fsharp" "fsharp"
# "latex"
"typst"
"justfile" "justfile"
"nix"
"typst"
]; ];
userSettings = { userSettings = {
vim_mode = true; vim_mode = true;
@ -35,30 +35,29 @@ in {
}; };
"Nix" = { "Nix" = {
language-servers = [ language-servers = [
"!nil" "nil"
"nixd"
]; ];
formatter = { # formatter = {
external.command = getExe pkgs.alejandra; # external.command = getExe pkgs.alejandra;
}; # };
};
"Rust" = {
formatter = {
external = {
command = getExe pkgs.rustfmt;
arguments = ["--edition" "2021"];
};
};
}; };
# "Rust" = {
# formatter = {
# external = {
# command = getExe pkgs.rustfmt;
# arguments = ["--edition" "2021"];
# };
# };
# };
"typst" = { "typst" = {
language-servers = ["tinymist"]; language-servers = ["tinymist"];
format_on_save = "on"; format_on_save = "on";
formatter = { # formatter = {
external = { # external = {
command = getExe pkgs.typstyle; # command = getExe pkgs.typstyle;
arguments = ["-i" "{buffer_path}"]; # arguments = ["-i" "{buffer_path}"];
}; # };
}; # };
}; };
"Python" = { "Python" = {
format_on_save = "on"; format_on_save = "on";
@ -73,6 +72,15 @@ in {
}; };
}; };
lsp = { lsp = {
bash-language-server = {
binary = {
path = getExe pkgs.bash-language-server;
env = {
"SHELLCHECK_PATH" = getExe pkgs.shellcheck;
"SHFMT_PATH" = getExe pkgs.shfmt;
};
};
};
fsautocomplete = { fsautocomplete = {
binary = { binary = {
path = getExe pkgs.fsautocomplete; path = getExe pkgs.fsautocomplete;
@ -91,32 +99,32 @@ in {
path = "${pkgs.clang-tools}/bin/clangd"; path = "${pkgs.clang-tools}/bin/clangd";
}; };
}; };
rust-analyzer = { # rust-analyzer = {
binary = { # binary = {
arguments = []; # arguments = [];
path = getExe pkgs.rust-analyzer; # path = getExe pkgs.rust-analyzer;
}; # };
}; # };
ruff = { ruff = {
binary = { binary = {
arguments = []; arguments = [];
path = getExe pkgs.ruff; path = getExe pkgs.ruff;
}; };
}; };
nixd = { # nixd = {
binary = {
arguments = [];
path = getExe pkgs.nixd;
};
initialization_options.formatting.command = [(getExe pkgs.alejandra)];
};
# nil = {
# binary = { # binary = {
# arguments = []; # arguments = [];
# path = getExe pkgs.nil; # path = getExe pkgs.nixd;
# }; # };
# initialization_options.formatting.command = [(getExe pkgs.alejandra)]; # initialization_options.formatting.command = [(getExe pkgs.alejandra)];
# }; # };
nil = {
binary = {
arguments = [];
path = getExe pkgs.nil;
};
settings.formatting.command = [(getExe pkgs.alejandra)];
};
# texlab = { # texlab = {
# binary = { # binary = {
# arguments = []; # arguments = [];
@ -129,6 +137,16 @@ in {
path = getExe pkgs.tinymist; path = getExe pkgs.tinymist;
}; };
}; };
vscode-json-language-server = {
binary = {
path = getExe pkgs.nodePackages.vscode-json-languageserver;
};
};
yaml-language-server = {
binary = {
path = getExe pkgs.yaml-language-server;
};
};
}; };
telemetry = { telemetry = {
diagnostics = false; diagnostics = false;

View File

@ -4,7 +4,7 @@
... ...
}: { }: {
boot.loader = { boot.loader = {
timeout = 3; timeout = 0;
efi.canTouchEfiVariables = true; efi.canTouchEfiVariables = true;
systemd-boot = { systemd-boot = {
consoleMode = "auto"; consoleMode = "auto";

View File

@ -11,23 +11,28 @@ in {
desktop.niri.enable = desktop.niri.enable =
mkEnableOption "enable niri desktop"; mkEnableOption "enable niri desktop";
}; };
config = mkIf cfg.enable { config = lib.mkMerge [
module.desktop.displayManager = "greetd"; (mkIf cfg.enable {
module.desktop.gnome-keyring.enable = true; module.desktop.displayManager = "greetd";
sound.pipewire.enable = true; module.desktop.gnome-keyring.enable = true;
sound.pipewire.enable = true;
security = { security = {
soteria.enable = true; # polkit agent in rust soteria.enable = true; # polkit agent in rust
pam.services.gtklock = {}; pam.services.gtklock = {};
}; };
programs.niri.enable = true; # wayland compositor in rust programs.niri.enable = true; # wayland compositor in rust
xdg.portal = { xdg.portal = {
enable = true; enable = true;
extraPortals = with pkgs; [ extraPortals = with pkgs; [xdg-desktop-portal-gnome xdg-desktop-portal-gtk];
xdg-desktop-portal-gnome config.niri.default = ["gnome" "gtk"];
xdg-desktop-portal-gtk };
]; })
config.niri.default = ["gnome" "gtk"]; (mkIf config.services.displayManager.autoLogin.enable {
}; services.greetd.settings.initial_session = {
}; command = "niri-session";
user = config.services.displayManager.autoLogin.user;
};
})
];
} }