From 1bc935d2d41085a7bafdad9f56eca2d8642b30d0 Mon Sep 17 00:00:00 2001 From: Henrik Lissner Date: Thu, 25 Feb 2016 18:36:31 -0500 Subject: [PATCH] Extract zgen and tmuxifier --- .gitmodules | 6 ------ install.sh | 4 +++- tmux/tmuxifier | 1 - zsh/zgen | 1 - zshrc | 7 ++++++- 5 files changed, 9 insertions(+), 10 deletions(-) delete mode 100644 .gitmodules delete mode 160000 tmux/tmuxifier delete mode 160000 zsh/zgen diff --git a/.gitmodules b/.gitmodules deleted file mode 100644 index 71de0cc3..00000000 --- a/.gitmodules +++ /dev/null @@ -1,6 +0,0 @@ -[submodule "zsh/zgen"] - path = zsh/zgen - url = https://github.com/tarjoilija/zgen -[submodule "tmux/tmuxifier"] - path = tmux/tmuxifier - url = https://github.com/jimeh/tmuxifier diff --git a/install.sh b/install.sh index 08d906bc..061adfa0 100755 --- a/install.sh +++ b/install.sh @@ -1,9 +1,11 @@ #!/usr/bin/env bash -_clone() { [[ -d "$2" ]] || git clone --recursve "$1" "$2"; } +_clone() { [ -d "$2" ] || git clone --recursive "$1" "$2"; } # In case this file was run via curl _clone https://github.com/hlissner/dotfiles ~/.dotfiles +_clone https://github.com/tarjoilija/zgen ~/.zgen +_clone https://github.com/jimeh/tmuxifier ~/.tmuxifier shopt -s extglob for rcfile in "${HOME}"/.dotfiles/!(.*|bin|scripts|*.md|install.sh) diff --git a/tmux/tmuxifier b/tmux/tmuxifier deleted file mode 160000 index dce4fb3a..00000000 --- a/tmux/tmuxifier +++ /dev/null @@ -1 +0,0 @@ -Subproject commit dce4fb3ad24d076ead56aa3eabbe7204ce43e991 diff --git a/zsh/zgen b/zsh/zgen deleted file mode 160000 index 3a0f26ed..00000000 --- a/zsh/zgen +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 3a0f26ed2f2d0b7b2f34fa5bac3c3a58d58cfc59 diff --git a/zshrc b/zshrc index 22d31552..58c5e814 100644 --- a/zshrc +++ b/zshrc @@ -1,11 +1,16 @@ ### zshrc # By Henrik Lissner +if [ ! -d ~/.zgen ]; then + echo "Zgen isn't installed! Run install.sh" + exit 1 +fi + ZSH_HIGHLIGHT_HIGHLIGHTERS=(main brackets) ZGEN_AUTOLOAD_COMPINIT=true [[ "${USER}" == "root" ]] && ZGEN_AUTOLOAD_COMPINIT=false -load zsh/zgen/zgen.zsh +source ~/.zgen/zgen.zsh if ! zgen saved; then echo "Creating zgen save" [[ -d "$CACHE_DIR" ]] && rm -f "$CACHE_DIR/*"