2022-03-09 01:15:44 +01:00
|
|
|
{ lib, pkgs, ... }:
|
2020-05-13 11:34:15 +02:00
|
|
|
let
|
|
|
|
shellAliases = import ./aliases.nix;
|
|
|
|
common = import ./common.nix;
|
2022-03-09 01:15:44 +01:00
|
|
|
|
|
|
|
theme = "dangerous";
|
|
|
|
themePackage = builtins.getAttr theme pkgs.myFishPlugins.themes; # Dynamically pick the theme path
|
2022-03-08 22:26:20 +01:00
|
|
|
in
|
|
|
|
{
|
2022-03-09 01:15:44 +01:00
|
|
|
home-manager.users.adrielus = {
|
|
|
|
# Source every file in the theme
|
|
|
|
xdg.configFile."fish/conf.d/plugin-${theme}.fish".text = lib.mkAfter ''
|
|
|
|
for f in $plugin_dir/*.fish
|
|
|
|
source $f
|
|
|
|
end
|
|
|
|
'';
|
|
|
|
|
|
|
|
programs.fish = {
|
|
|
|
inherit shellAliases;
|
|
|
|
|
|
|
|
enable = true;
|
|
|
|
plugins = with pkgs; [
|
|
|
|
myFishPlugins.z # jump around the file system with ease (might replace with autojump)
|
|
|
|
themePackage # theme
|
|
|
|
];
|
|
|
|
|
|
|
|
shellInit = ''
|
|
|
|
source ${../../../dotfiles/fish/config.fish}
|
2022-03-08 22:26:20 +01:00
|
|
|
|
2022-03-09 01:15:44 +01:00
|
|
|
# Source the entire oh-my-fish lib
|
|
|
|
for f in ${pkgs.myFishPlugins.oh-my-fish}/lib/git/**/*.fish
|
|
|
|
source $f
|
|
|
|
end
|
2022-03-08 22:26:20 +01:00
|
|
|
|
2022-03-09 01:15:44 +01:00
|
|
|
# if [ "${theme}" = "dangerous" ]
|
|
|
|
set dangerous_colors 000000 333333 666666 ff4ff0 0088ff ff6600 ff0000 ff0033 3300ff 0000ff 00ffff 00ff00
|
|
|
|
# end
|
2020-04-12 18:57:47 +02:00
|
|
|
|
2022-03-09 01:15:44 +01:00
|
|
|
${common.shellInit}
|
|
|
|
'';
|
|
|
|
};
|
2021-11-29 15:00:11 +01:00
|
|
|
};
|
2020-04-12 18:57:47 +02:00
|
|
|
}
|