mirror of
https://codeberg.org/leana8959/.files.git
synced 2025-12-06 14:49:14 +00:00
add(nix): nixified common
This commit is contained in:
parent
f97e3f8be8
commit
074e78751a
9 changed files with 168 additions and 93 deletions
|
|
@ -9,6 +9,17 @@
|
|||
stateVersion = "23.11";
|
||||
};
|
||||
|
||||
imports = [
|
||||
./fish
|
||||
|
||||
./starship
|
||||
./fzf
|
||||
./git
|
||||
./btop
|
||||
|
||||
./neovim
|
||||
];
|
||||
|
||||
# TODO: potentially drop legacy support
|
||||
programs = let
|
||||
inherit (builtins) readFile foldl' map listToAttrs concatMap;
|
||||
|
|
@ -18,77 +29,7 @@
|
|||
enable = true;
|
||||
nix-direnv.enable = true;
|
||||
};
|
||||
starship = {
|
||||
enable = true;
|
||||
enableFishIntegration = true;
|
||||
settings = fromTOML (readFile ../../../.config/starship.toml);
|
||||
};
|
||||
fish = {
|
||||
enable = true;
|
||||
shellInit = readFile ./fish/shellInit.fish;
|
||||
interactiveShellInit = let
|
||||
readGlobalFishConfigs = ns:
|
||||
foldl' (l: r: l + "\n" + r) ""
|
||||
(
|
||||
map
|
||||
(n: readFile ../../../.config/fish/conf.d/${n}.fish)
|
||||
ns
|
||||
);
|
||||
in
|
||||
readFile ./fish/interactiveShellInit.fish
|
||||
+ readGlobalFishConfigs [
|
||||
"alias"
|
||||
"bind"
|
||||
"colorscheme"
|
||||
"locale"
|
||||
];
|
||||
functions = let
|
||||
makeFishFunctions = ns:
|
||||
listToAttrs
|
||||
(
|
||||
concatMap
|
||||
(n: [
|
||||
{
|
||||
name = n;
|
||||
value = {body = readFile ../../../.config/fish/functions/${n}.fish;};
|
||||
}
|
||||
])
|
||||
ns
|
||||
);
|
||||
in
|
||||
makeFishFunctions [
|
||||
"clone_to_repos"
|
||||
"file_extension"
|
||||
"file_mantissa"
|
||||
"fish_command_not_found"
|
||||
"fish_greeting"
|
||||
"fish_remove_path"
|
||||
"install_fisher"
|
||||
"largest-objects-in-repo"
|
||||
"snakecase"
|
||||
"timestamp"
|
||||
"tmux_attach"
|
||||
"tmux_home"
|
||||
"tmux_last"
|
||||
"tmux_sessionizer"
|
||||
"update_dotfiles"
|
||||
];
|
||||
plugins = let
|
||||
makeFishPlugins = ns: (concatMap
|
||||
(n: [
|
||||
{
|
||||
name = n;
|
||||
src = pkgs.fishPlugins.${n};
|
||||
}
|
||||
])
|
||||
ns);
|
||||
in
|
||||
makeFishPlugins [
|
||||
"fzf-fish"
|
||||
"colored-man-pages"
|
||||
"sponge"
|
||||
];
|
||||
};
|
||||
ripgrep.enable = true;
|
||||
};
|
||||
|
||||
home.packages = with pkgs; [
|
||||
|
|
@ -96,13 +37,10 @@
|
|||
figlet
|
||||
gnused
|
||||
stow
|
||||
ripgrep
|
||||
fd
|
||||
fzf
|
||||
vivid
|
||||
|
||||
# utils
|
||||
btop
|
||||
tree
|
||||
rsync
|
||||
tldr
|
||||
|
|
@ -110,14 +48,7 @@
|
|||
|
||||
# Editors
|
||||
tmux
|
||||
neovim
|
||||
vim
|
||||
gcc
|
||||
|
||||
# git
|
||||
git
|
||||
git-lfs
|
||||
bat
|
||||
delta
|
||||
];
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue