mirror of https://github.com/wlcx/home.git
Add zsh fzf, tweak completion
This commit is contained in:
parent
1dd386ed3a
commit
01fb3d60a4
|
@ -6,7 +6,8 @@ in {
|
||||||
home.sessionVariables = {
|
home.sessionVariables = {
|
||||||
"PATH" = "$HOME/.local/bin:$PATH";
|
"PATH" = "$HOME/.local/bin:$PATH";
|
||||||
"EDITOR" = "vim";
|
"EDITOR" = "vim";
|
||||||
"WORDCHARS" = "\${WORDCHARS//[\\/.]/}"; # ctrl-w on paths without make angery
|
"WORDCHARS" =
|
||||||
|
"\${WORDCHARS//[\\/.]/}"; # ctrl-w on paths without make angery
|
||||||
};
|
};
|
||||||
programs = {
|
programs = {
|
||||||
home-manager.enable = true;
|
home-manager.enable = true;
|
||||||
|
@ -20,12 +21,32 @@ in {
|
||||||
hmswitch = ''home-manager switch --flake ".#$(hostname -s)"'';
|
hmswitch = ''home-manager switch --flake ".#$(hostname -s)"'';
|
||||||
nrswitch = "sudo nixos-rebuild switch --flake '.#'";
|
nrswitch = "sudo nixos-rebuild switch --flake '.#'";
|
||||||
};
|
};
|
||||||
|
# Extra .zshrc stuff
|
||||||
plugins = [{
|
initExtra = ''
|
||||||
name = "zsh-z";
|
# zstyle ':completion:*' menu select # fancy interactive autocomplete
|
||||||
file = "share/zsh-z/zsh-z.plugin.zsh";
|
zstyle ':completion:*' matcher-list 'm:{a-z}={A-Za-z}' # tabcomplete lower to upper case
|
||||||
src = pkgs.zsh-z;
|
'';
|
||||||
}];
|
enableSyntaxHighlighting = true;
|
||||||
|
plugins = [
|
||||||
|
{
|
||||||
|
name = "fzf-tab";
|
||||||
|
src = pkgs.fetchFromGitHub {
|
||||||
|
owner = "aloxaf";
|
||||||
|
repo = "fzf-tab";
|
||||||
|
rev = "master";
|
||||||
|
sha256 = "y9MuxJzXi1i+zCBzqjjCHL9uHzq/peDZEb3MByMm0Wg=";
|
||||||
|
};
|
||||||
|
}
|
||||||
|
{
|
||||||
|
name = "zsh-z";
|
||||||
|
src = pkgs.fetchFromGitHub {
|
||||||
|
owner = "agkozak";
|
||||||
|
repo = "zsh-z";
|
||||||
|
rev = "master";
|
||||||
|
sha256 = "1A6WZ+fJSf2WKZD7CYJB/pbgwV2mX+X8qInqQLeuT78=";
|
||||||
|
};
|
||||||
|
}
|
||||||
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
exa = {
|
exa = {
|
||||||
|
@ -43,7 +64,8 @@ in {
|
||||||
hostname.format = "[$hostname]($style) ";
|
hostname.format = "[$hostname]($style) ";
|
||||||
directory = { truncation_length = -1; };
|
directory = { truncation_length = -1; };
|
||||||
git_branch.format = "[$symbol$branch]($style) ";
|
git_branch.format = "[$symbol$branch]($style) ";
|
||||||
python.format = "[py \${pyenv_prefix}(\${version} )(\\($virtualenv\\) )]($style)";
|
python.format =
|
||||||
|
"[py \${pyenv_prefix}(\${version} )(\\($virtualenv\\) )]($style)";
|
||||||
nodejs.format = "[js ($version )]($style)";
|
nodejs.format = "[js ($version )]($style)";
|
||||||
nix_shell.format = "[nix $state( \\($name\\))]($style) ";
|
nix_shell.format = "[nix $state( \\($name\\))]($style) ";
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in New Issue