nixos-config/homes/common/terminal.nix

60 lines
1.4 KiB
Nix
Raw Normal View History

2024-04-21 21:15:45 +02:00
{ lib, pkgs, assets, ... }:
2023-12-23 00:11:26 +01:00
{
programs.zsh = {
enable = true;
2023-12-23 22:46:58 +01:00
defaultKeymap = lib.mkDefault "viins";
2023-12-23 00:11:26 +01:00
};
programs.bash = {
enable = true;
bashrcExtra = ''
set -o vi
'';
};
2024-01-14 21:03:18 +01:00
programs.thefuck.enable = true;
2023-12-23 00:11:26 +01:00
# a better cat
programs.bat = {
enable = true;
2024-05-24 21:08:34 +02:00
#config.theme = "gruvbox-light";
2023-12-23 00:11:26 +01:00
};
home.shellAliases.cat = "${pkgs.bat}/bin/bat --theme='gruvbox-light'";
home.shellAliases.llt = "${pkgs.eza}/bin/exa -a --tree";
# use z instead of cd
# use zi to fuzzy search through all registered directories
programs.zoxide = {
enable = true;
enableZshIntegration = true;
};
# provide better `Ctrl+r` command in terminal
programs.atuin = {
enable = true;
enableBashIntegration = true;
enableZshIntegration = true;
#package = pkgs.atuin;
package = pkgs.atuin.overrideAttrs (_old: {
2024-04-19 21:07:41 +02:00
# as cursed as doing mitigations=off in the kernel command line
2024-04-21 21:15:45 +02:00
patches = [ "${assets}/0001-make-atuin-on-zfs-fast-again.patch" ];
2024-04-19 21:07:41 +02:00
});
2023-12-23 00:11:26 +01:00
settings = {
auto_sync = true;
sync_frequency = "5m";
2023-12-23 22:46:58 +01:00
sync_address = "http://chungus.private:8888";
search_mode = "fuzzy";
style = "full";
inline_height = 20;
2024-03-06 13:22:02 +01:00
keymap_mode = "vim-normal";
# With workspace filtering enabled, Atuin will filter for commands executed
# in any directory within a git repository tree.
workspaces = true;
2023-12-23 00:11:26 +01:00
};
};
}