summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTill Höppner2017-05-15 14:28:36 +0200
committerTill Höppner2017-05-15 14:28:36 +0200
commitb2bf9b7a2d72f91d75f2222a70d54eaeb8b04d61 (patch)
treea60bf585bcdd84ffa3d709dafde8ea1a79ff40c6
parentddbd1887ed527c87cca969c0e3e0f48afcf4b4fb (diff)
downloadzsh-b2bf9b7a2d72f91d75f2222a70d54eaeb8b04d61.tar.gz
zsh-b2bf9b7a2d72f91d75f2222a70d54eaeb8b04d61.tar.xz
zsh-b2bf9b7a2d72f91d75f2222a70d54eaeb8b04d61.zip
Ditch zplug for manual management
-rw-r--r--.gitmodules11
m---------plugins/01-fast-syntax-highlighting (renamed from plugins/fast-syntax-highlighting)0
m---------plugins/02-zsh-history-substring-search0
m---------plugins/03-zsh-autosuggestions0
m---------zplug0
-rw-r--r--zshrc30
6 files changed, 27 insertions, 14 deletions
diff --git a/.gitmodules b/.gitmodules
index 9e01c66..817de0a 100644
--- a/.gitmodules
+++ b/.gitmodules
@@ -1,6 +1,9 @@
-[submodule "zplug"]
- path = zplug
- url = gh:zplug/zplug
[submodule "plugins/fast-syntax-highlighting"]
- path = plugins/fast-syntax-highlighting
+ path = plugins/01-fast-syntax-highlighting
url = https://github.com/zdharma/fast-syntax-highlighting
+[submodule "plugins/zsh-autosuggestions"]
+ path = plugins/03-zsh-autosuggestions
+ url = https://github.com/zsh-users/zsh-autosuggestions
+[submodule "plugins/zsh-history-substring-search"]
+ path = plugins/02-zsh-history-substring-search
+ url = https://github.com/zsh-users/zsh-history-substring-search
diff --git a/plugins/fast-syntax-highlighting b/plugins/01-fast-syntax-highlighting
-Subproject 7d6524e6fbdfa6c3bdd5cf840f6aac0bd39f514
+Subproject 7d6524e6fbdfa6c3bdd5cf840f6aac0bd39f514
diff --git a/plugins/02-zsh-history-substring-search b/plugins/02-zsh-history-substring-search
new file mode 160000
+Subproject c750a17757478686b671f6cdd3f2fc3cfb078ed
diff --git a/plugins/03-zsh-autosuggestions b/plugins/03-zsh-autosuggestions
new file mode 160000
+Subproject fedc22e9bbd046867860e772d7d6787f5dae9d4
diff --git a/zplug b/zplug
deleted file mode 160000
-Subproject 06c6f33bf1543f30d26835867fb73d599e060d0
diff --git a/zshrc b/zshrc
index f410736..5385352 100644
--- a/zshrc
+++ b/zshrc
@@ -1,14 +1,24 @@
-source /cfg/zsh/zplug/init.zsh
+# Determine location of this file from the assumption that
+# it is linked to ~/.zshrc. This is required to find the
+# config files and plugins located relative to this file
-zstyle ':zplug:tag' 'from' 'local'
+# directory this file is in
+CFG_DIR=$(dirname $(readlink -f ~/.zshrc))
-zplug 'zdharma/fast-syntax-highlighting'
-
-if ! zplug check --verbose; then
- printf "Install? [y/N]: "
- if read -q; then
- echo; zplug install
+for plugin in $CFG_DIR/plugins/*(N); do
+ # add *.zsh if no *.plugin.zsh found
+ local files=( $plugin/*.plugin.zsh(N) )
+ if [ ${#files[@]} -eq 0 ]; then
+ files=( $plugin/*.zsh(N) )
fi
-fi
+
+ for file in $files; source $file
+ fpath=($fpath $plugin)
+done
+
+fpath=($CFG_DIR/functions $fpath)
+for fn in $CFG_DIR/functions/*(.N); autoload $(basename $fn)
-zplug load --verbose
+for conf in $CFG_DIR/conf.d/*(.N); do
+ source "$conf"
+done