configuration.nix/home/programs/files.nix

46 lines
1.2 KiB
Nix
Raw Normal View History

2024-05-14 23:15:50 +05:30
{ config, ... }: {
2024-05-11 11:47:02 +05:30
programs = {
fd = {
enable = true;
ignores = [ ".git/" "node_modules/" ];
};
yazi = {
enable = true;
enableZshIntegration = true;
2024-05-13 00:33:44 +05:30
settings = {
manager = {
sort_by = "natural";
sort_dir_first = true;
show_hidden = true;
};
preview = {
image_filter = "lanczos3";
2024-05-14 23:15:50 +05:30
image_quality = 90;
2024-05-13 00:33:44 +05:30
};
2024-05-14 23:15:50 +05:30
opener = {
open-image = [
{ run = "${config.programs.imv.package}/bin/imv $0"; orphan = true; }
];
edit-text = [
{ run = "${config.programs.neovim.package}/bin/nvim $0"; block = true; }
];
play = [
{ run = "${config.programs.mpv.package}/bin/mpv $0"; orphan = true; }
];
terminal = [
{ run = "${config.programs.kitty.package}/bin/kitty --class=yazi -d=$0"; orphan = true; }
];
};
open.rules = [
{ mime = "image/*"; use = "open-image"; }
{ mime = "text/*"; use = [ "edit-text" ]; }
{ mime = "video/*"; use = [ "play" ]; }
{ mime = "inode/directory"; use = [ "terminal" ]; }
];
2024-05-13 00:33:44 +05:30
};
2024-05-11 11:47:02 +05:30
};
2024-05-11 11:42:55 +05:30
};
2024-05-11 11:47:02 +05:30
2023-04-08 18:32:45 +05:30
}