aboutsummaryrefslogtreecommitdiffstats
path: root/zsh/.zshrc
diff options
context:
space:
mode:
authorJohannes Löthberg <johannes@kyriasis.com>2014-09-24 13:24:27 +0200
committerJohannes Löthberg <johannes@kyriasis.com>2014-09-24 13:24:27 +0200
commitb99973d37cd6dcdf070da9bd2724810445968ef9 (patch)
treec63b697856f0373c2bddb28c6052632f2209bdca /zsh/.zshrc
parent7d6b6755e6fffe1e1d6a36c46ea0ea9032f5d541 (diff)
downloaddotfiles-b99973d37cd6dcdf070da9bd2724810445968ef9.tar.xz
zsh/zshrc: Reorganize slightly
Diffstat (limited to 'zsh/.zshrc')
-rw-r--r--zsh/.zshrc29
1 files changed, 15 insertions, 14 deletions
diff --git a/zsh/.zshrc b/zsh/.zshrc
index 4b83f19..073287d 100644
--- a/zsh/.zshrc
+++ b/zsh/.zshrc
@@ -2,8 +2,12 @@ HISTFILE=~/.config/zsh/.zsh_history
HISTSIZE=500000
SAVEHIST=500000
-fpath=(~/.local/share/zsh/completion $fpath)
-zstyle :compinstall filename "$HOME/.config/zsh/.zshrc"
+zstyle :compinstall filename "$ZDOTDIR"/.zshrc
+
+# Menu completion
+zstyle ':completion:*' menu select
+zstyle ':completion:*' use-cache on
+zstyle ':completion:*' rehash yes
autoload -Uz colors \
compinit \
@@ -15,8 +19,6 @@ compinit
promptinit
colors
-zmodload zsh/mapfile
-
setopt autocd \
complete_aliases \
glob_dots \
@@ -34,20 +36,19 @@ setopt autocd \
prompt_subst \
notify
-# Menu completion
-zstyle ':completion:*' menu select
-zstyle ':completion:*' use-cache on
-zstyle ':completion:*' rehash yes
-
+# "This associative array takes as keys the names of files; the resulting
+# value is the content of the file"
+zmodload zsh/mapfile
-source "$ZDOTDIR"/prompt.zsh
-source "$ZDOTDIR"/aliases.zsh
source "$ZDOTDIR"/keybindings.zsh
-
-[[ -f "$ZDOTDIR"/zshrc-"$(hostname -s)" ]] && \
- source "$ZDOTDIR"/zshrc-"$(hostname -s)"
+source "$ZDOTDIR"/aliases.zsh # aliases and functions.
+source "$ZDOTDIR"/prompt.zsh # sets the prompt
if [[ -n "$VTE_VERSION" ]]; then
source /etc/profile.d/vte.sh
__vte_prompt_command
fi
+
+if [[ -f "$ZDOTDIR"/zshrc-"$SHORTHOST" ]]; then
+ source "$ZDOTDIR"/zshrc-"$SHORTHOST"
+fi