feat(fish): Add abbrs/aliases

This commit is contained in:
punkfairie 2024-11-03 15:00:19 -08:00
parent 1e1af93236
commit 82b36c590c
2 changed files with 37 additions and 3 deletions

View file

@ -5,17 +5,19 @@
"${config.home.homeDirectory}/.local/bin"
];
sessionVariables = {
sessionVariables = rec {
HACK = "${config.home.homeDirectory}/hackin";
# TODO: remove this when neovim is installed.
EDITOR = "nvim";
VISUAL = "${config.home.sessionVariables.VISUAL}";
SUDO_EDITOR = "${config.home.sessionVariables.VISUAL}";
VISUAL = "${EDITOR}";
SUDO_EDITOR = "${EDITOR}";
};
shellAliases = {
c = "clear";
e = "${config.home.sessionVariables.EDITOR}";
v = "${config.home.sessionVariables.EDITOR}";
};
};

View file

@ -29,5 +29,37 @@
src = autopair;
}
];
shellInit = # fish
''
set -g fish_key_bindings fish_vi_key_bindings
'';
shellAbbrs = {
cp = {
position = "command";
expansion = "cp -iv";
};
mkdir = {
position = "command";
expansion = "mkdir -pv";
};
mv = {
position = "command";
expansion = "mv -iv";
};
rm = {
position = "command";
expansion = "rm -r";
};
grep = {
position = "command";
expansion = "grep --color=auto";
};
};
};
}