refactor works on lio host
This commit is contained in:
parent
1d9c4beaf3
commit
f0c096edec
73 changed files with 2214 additions and 1091 deletions
41
common/_home_manager/mods/zsh.nix
Normal file
41
common/_home_manager/mods/zsh.nix
Normal file
|
@ -0,0 +1,41 @@
|
|||
{ ... }:
|
||||
{
|
||||
programs.zsh = {
|
||||
enable = true;
|
||||
autosuggestion.enable = true;
|
||||
|
||||
shellAliases = { };
|
||||
|
||||
defaultKeymap = "emacs";
|
||||
|
||||
initExtra = ''
|
||||
# Set editor to neovim, TODO only do this if mod.neovim is enabled
|
||||
export EDITOR=nvim
|
||||
export VISUAL=nvim
|
||||
|
||||
# Enable editing command in external editor
|
||||
autoload -Uz edit-command-line
|
||||
zle -N edit-command-line
|
||||
# Try multiple bindings for edit-command-line
|
||||
bindkey '^X^E' edit-command-line # Traditional Ctrl+X,Ctrl+E binding
|
||||
bindkey '^[^M' edit-command-line # Alt+Enter
|
||||
# Note: Ctrl+Enter might not be distinctly capturable in all terminals
|
||||
|
||||
# Make home/end and ctrl + left/right nav how I expect them to like in bash
|
||||
bindkey "\e[1~" beginning-of-line
|
||||
bindkey "\e[4~" end-of-line
|
||||
bindkey '^[[1;5D' emacs-backward-word
|
||||
bindkey '^[[1;5C' emacs-forward-word
|
||||
|
||||
# Auto completion/suggestions/and case insensitivity
|
||||
autoload -Uz compinit && compinit
|
||||
setopt correct
|
||||
setopt extendedglob
|
||||
setopt nocaseglob
|
||||
zstyle ':completion:*' matcher-list 'm:{a-zA-Z}={A-Za-z}' # Case insensitive tab completion
|
||||
zstyle ':completion:*' list-colors "''${(s.:.)LS_COLORS}" # Colored completion (different colors for dirs/files/etc)
|
||||
zstyle ':completion:*' rehash true # automatically find new executables in path
|
||||
'';
|
||||
};
|
||||
}
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue