Initial commit
This commit is contained in:
commit
a43b5a6a1a
12 changed files with 550 additions and 0 deletions
modules
42
modules/zsh.nix
Normal file
42
modules/zsh.nix
Normal file
|
@ -0,0 +1,42 @@
|
|||
{ config, lib, ... }:
|
||||
with lib;
|
||||
let cfg = config.voidcruiser.zsh;
|
||||
in {
|
||||
options.voidcruiser.zsh = {
|
||||
enable = mkEnableOption "Enables opinionated zsh configuration";
|
||||
skim.enable = mkEnableOption "Enables skim support for shell history";
|
||||
highlightStyle = mkOption {
|
||||
type = types.str;
|
||||
default = "fg=magenta,bg=black,bold,underline";
|
||||
description = ''
|
||||
Colors for zsh autosuggestions. Check the documentation for more info.
|
||||
'';
|
||||
};
|
||||
};
|
||||
config = mkIf cfg.enable {
|
||||
programs = {
|
||||
skim.keybindings = cfg.skim.enable;
|
||||
zsh = {
|
||||
enable = true;
|
||||
enableCompletion = true;
|
||||
autosuggestions = {
|
||||
enable = true;
|
||||
highlightStyle = cfg.highlightStyle;
|
||||
async = true;
|
||||
};
|
||||
syntaxHighlighting = {
|
||||
enable = true;
|
||||
};
|
||||
shellAliases = {
|
||||
ls = "ls --color=tty";
|
||||
l = "ls -lah";
|
||||
la = "ls -a";
|
||||
lr = "ls -rt";
|
||||
llr = "ls -lhrt";
|
||||
llar = "ls -lhArt";
|
||||
grep = "grep --color=auto";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue