From c0aad51afd2e2336c3eadc4bf71fb738398812ce Mon Sep 17 00:00:00 2001 From: John D Pell Date: Sun, 10 Oct 2021 00:07:48 -0700 Subject: [PATCH] main: move Jekyll stuff to plugins/jekyll If the user doesn't load the Jekyll plugin, then don't load any Jeykll stuff. --- bash_it.sh | 7 ------- plugins/available/jekyll.plugin.bash | 5 +++++ 2 files changed, 5 insertions(+), 7 deletions(-) diff --git a/bash_it.sh b/bash_it.sh index de655e81..bda3407e 100755 --- a/bash_it.sh +++ b/bash_it.sh @@ -137,13 +137,6 @@ elif [ -s /Applications/Preview.app ]; then PREVIEW="/Applications/Preview.app" fi -# Load all the Jekyll stuff - -if [ -e "$HOME/.jekyllconfig" ]; then - # shellcheck disable=SC1090 - . "$HOME/.jekyllconfig" -fi - # BASH_IT_RELOAD_LEGACY is set. if ! _command_exists reload && [[ -n "${BASH_IT_RELOAD_LEGACY:-}" ]]; then case $OSTYPE in diff --git a/plugins/available/jekyll.plugin.bash b/plugins/available/jekyll.plugin.bash index 7fef0065..f647d4a0 100644 --- a/plugins/available/jekyll.plugin.bash +++ b/plugins/available/jekyll.plugin.bash @@ -315,3 +315,8 @@ function deploysite() { builtin cd "${SITE}" || return rsync -rz "${REMOTE?}" } + +# Load the Jekyll config +if [[ -s "$HOME/.jekyllconfig" ]]; then + source "$HOME/.jekyllconfig" +fi