From 37a28c07c5752711e5d1f4686a2b3f17d62ce3b7 Mon Sep 17 00:00:00 2001 From: Simon Ruderich Date: Sat, 29 Nov 2014 11:26:13 +0100 Subject: [PATCH] zsh/rc: improve comments --- zsh/rc | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/zsh/rc b/zsh/rc index 33f840e..c1ee1d4 100644 --- a/zsh/rc +++ b/zsh/rc @@ -86,7 +86,7 @@ setopt longlistjobs # Use Vi(m) style key bindings. bindkey -v -# Use jk to exit insert mode (jj is too slow). +# Use jk to exit insert mode (jj is too slow to type). bindkey 'jk' vi-cmd-mode # I don't need the arrow keys, I use ^N and ^P for this (see below). @@ -211,7 +211,8 @@ autoload -Uz colors; colors zmodload zsh/datetime # Some shortcuts for colors. The %{...%} tells zsh that the data in between -# doesn't need any space, necessary for correct prompt drawing. +# doesn't need any space, necessary for correct prompt drawing. Use %F{color} +# in more recent zsh versions (here compatibility is important). local red="%{${fg[red]}%}" local blue="%{${fg[blue]}%}" local green="%{${fg[green]}%}" @@ -777,7 +778,7 @@ zle -C complete-files complete-word _generic zstyle ':completion:complete-files:*' completer _files bindkey '^F' complete-files -# Completion for my wrapper scripts +# Completion for my wrapper scripts. compdef slocate=locate compdef srsync=rsync compdef srsync-incremental=rsync @@ -1047,7 +1048,7 @@ zshrc_restart_precmd() { fi # Try to start a new interactive shell. If it fails, something is wrong. - # Don't kill our current session by execing it. + # Don't kill our current session by execing it, abort instead. zsh -i -c 'exit 42' if [[ $? -ne 42 ]]; then echo -n ${fg_bold[red]} -- 2.44.1