Skip to content

Commit

Permalink
nvim: add plugin test script
Browse files Browse the repository at this point in the history
Plugins that cause errors at startup are hard to debug. This script
removes all the plugins, and adds them back in one by one, testing nvim
each step to see what happened. Bad plugins are quarantined.
  • Loading branch information
mx-moth committed May 5, 2016
1 parent 6c52a5d commit 49f26db
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions config/nvim/test.sh
@@ -0,0 +1,24 @@
#!/bin/bash

nvim=~/.config/nvim
mkdir -p $nvim/bundle.bad
mv "$nvim"/bundle/* "$nvim"/bundle.back
mv "$nvim"/bundle.back/neomake "$nvim"/bundle
mv "$nvim"/bundle.back/colors "$nvim"/bundle
mv "$nvim"/bundle.back/airline "$nvim"/bundle

for x in $nvim/bundle.back/* ; do
plugin=$( basename "$x")
mv "$nvim/bundle.back/$plugin" "$nvim/bundle/$plugin"
nvim "$@"
echo "plugin $plugin"
read -p "did it work? " -N1 yn
echo ""
case "$yn" in
[nN])
echo "Quarantine $plugin"
mv "$nvim/bundle/$plugin" "$nvim/bundle.bad/$plugin"
;;
*)
esac
done

0 comments on commit 49f26db

Please sign in to comment.