refactor!: restructure and document configuration
This commit is contained in:
parent
4a02e072a7
commit
f87f9995be
126 changed files with 957 additions and 590 deletions
30
shared/home-manager/dotfiles/fish/Catppuccin-Frappe.theme
Normal file
30
shared/home-manager/dotfiles/fish/Catppuccin-Frappe.theme
Normal file
|
@ -0,0 +1,30 @@
|
|||
# name: 'Catppuccin frappe'
|
||||
# url: 'https://github.com/catppuccin/fish'
|
||||
# preferred_background: 303446
|
||||
|
||||
fish_color_normal c6d0f5
|
||||
fish_color_command 8caaee
|
||||
fish_color_param eebebe
|
||||
fish_color_keyword e78284
|
||||
fish_color_quote a6d189
|
||||
fish_color_redirection f4b8e4
|
||||
fish_color_end ef9f76
|
||||
fish_color_comment 838ba7
|
||||
fish_color_error e78284
|
||||
fish_color_gray 737994
|
||||
fish_color_selection --background=414559
|
||||
fish_color_search_match --background=414559
|
||||
fish_color_option a6d189
|
||||
fish_color_operator f4b8e4
|
||||
fish_color_escape ea999c
|
||||
fish_color_autosuggestion 737994
|
||||
fish_color_cancel e78284
|
||||
fish_color_cwd e5c890
|
||||
fish_color_user 81c8be
|
||||
fish_color_host 8caaee
|
||||
fish_color_host_remote a6d189
|
||||
fish_color_status e78284
|
||||
fish_pager_color_progress 737994
|
||||
fish_pager_color_prefix f4b8e4
|
||||
fish_pager_color_completion c6d0f5
|
||||
fish_pager_color_description 737994
|
76
shared/home-manager/dotfiles/fish/default.nix
Normal file
76
shared/home-manager/dotfiles/fish/default.nix
Normal file
|
@ -0,0 +1,76 @@
|
|||
{ ... }:
|
||||
|
||||
{
|
||||
home.file = {
|
||||
# Cattpuccin theme for fish shell.
|
||||
".config/fish/themes/Catppuccin-Frappe.theme".source = ./Catppuccin-Frappe.theme;
|
||||
};
|
||||
|
||||
programs.fish = {
|
||||
enable = true;
|
||||
|
||||
interactiveShellInit = ''
|
||||
## Set vim mode
|
||||
set -g fish_key_bindings fish_vi_key_bindings
|
||||
|
||||
# Configure FZF
|
||||
set -x FZF_DEFAULT_OPTS '--color=fg:#f8f8f2,hl:#bd93f9 --color=fg+:#f8f8f2,bg+:#44475a,hl+:#bd93f9 --color=info:#ffb86c,prompt:#50fa7b,pointer:#ff79c6 --color=marker:#ff79c6,spinner:#ffb86c,header:#6272a4 --layout=reverse --height 50%'
|
||||
|
||||
# Remove welcome message
|
||||
set -x fish_greeting ""
|
||||
|
||||
## Add directories to $PATH
|
||||
fish_add_path /home/wizardlink/.local/share/scripts \
|
||||
/home/wizardlink/.config/emacs/bin \
|
||||
/home/wizardlink/.nimble/bin \
|
||||
/home/wizardlink/.cargo/bin \
|
||||
/home/wizardlink/.local/bin \
|
||||
/lib/flatpak/exports/bin
|
||||
|
||||
zoxide init --cmd cd fish | source
|
||||
'';
|
||||
|
||||
shellAbbrs = {
|
||||
z = "zoxide";
|
||||
pkg_expr = {
|
||||
position = "anywhere";
|
||||
expansion = "--expr 'with import <nixpkgs> { % }; '";
|
||||
};
|
||||
impure_cmd = {
|
||||
position = "command";
|
||||
expansion = "NIXPKGS_ALLOW_UNFREE=1 nix % --impure";
|
||||
};
|
||||
};
|
||||
|
||||
shellAliases = {
|
||||
del = "trash_file";
|
||||
dev = "nix develop -c fish";
|
||||
doom = "~/.config/emacs/bin/doom";
|
||||
repl = "NIXPKGS_ALLOW_UNFREE=1 nix repl --impure --extra-experimental-features 'flakes' nixpkgs#legacyPackages.x86_64-linux";
|
||||
};
|
||||
|
||||
functions = {
|
||||
fish_prompt.body = ''
|
||||
set_color CC241D
|
||||
echo '&' (set_color normal)
|
||||
'';
|
||||
|
||||
fzf_edit.body = ''
|
||||
fzf --multi --bind 'enter:become(nvim {+})'
|
||||
'';
|
||||
|
||||
trash_file.body = ''
|
||||
mv $argv ~/.local/share/Trash
|
||||
'';
|
||||
|
||||
ya.body = ''
|
||||
set tmp (mktemp -t "yazi-cwd.XXXXX")
|
||||
yazi $argv --cwd-file="$tmp"
|
||||
if set cwd (cat -- "$tmp"); and [ -n "$cwd" ]; and [ "$cwd" != "$PWD" ]
|
||||
cd -- "$cwd"
|
||||
end
|
||||
rm -f -- "$tmp"
|
||||
'';
|
||||
};
|
||||
};
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue