wip
This commit is contained in:
parent
9c487ce6d2
commit
74357e75d7
2 changed files with 12 additions and 28 deletions
|
@ -1,26 +0,0 @@
|
|||
_plugins() {
|
||||
local bash_dir="$HOME/.bash/plugins"
|
||||
if [ -d "$bash_dir" ]; then
|
||||
echo_info "Plugins will be loadet.."
|
||||
|
||||
# ─< plugins to configure (usually just the filename in the plugins list) >───────────────
|
||||
local plugAutopairs="autopairs.sh"
|
||||
local sshCompletion="ssh"
|
||||
|
||||
# ─< active plugins >─────────────────────────────────────────────────────────────────────
|
||||
plugins=(
|
||||
"$plugAutopairs"
|
||||
"$sshCompletion"
|
||||
)
|
||||
|
||||
# ─< loop through and source the plugins >────────────────────────────────────────────────
|
||||
for plugin in "${plugins[@]}"; do
|
||||
if [ -f "${bash_dir}/${plugin}" ]; then
|
||||
echo_plugin "${bash_dir}/${plugin}"
|
||||
. "${bash_dir}/${plugin}"
|
||||
fi
|
||||
done
|
||||
fi
|
||||
}
|
||||
|
||||
_plugins
|
14
.bashrc
14
.bashrc
|
@ -86,6 +86,12 @@ check_root() {
|
|||
fi
|
||||
}
|
||||
|
||||
_source() {
|
||||
[[ -e "$1" ]] &&
|
||||
. "$1" &&
|
||||
echo "Sourced $1"
|
||||
}
|
||||
|
||||
_sources() {
|
||||
local sourceDir="$HOME/.bash"
|
||||
local sourceOptions=(
|
||||
|
@ -282,12 +288,16 @@ main() {
|
|||
# _sources
|
||||
# _blesh
|
||||
_init
|
||||
[[ -e "$HOME/.bash_aliases" ]] &&
|
||||
. "$HOME/.bash_aliases"
|
||||
|
||||
_color_prompt_
|
||||
_env
|
||||
check_root
|
||||
_end
|
||||
|
||||
_source "$HOME/.bash_aliases"
|
||||
_source "$HOME/.bash/plugins/autopairs.sh"
|
||||
_source "$HOME/.fzf/shell/completion.bash"
|
||||
_source "$HOME/.fzf/shell/key-bindings.bash"
|
||||
}
|
||||
|
||||
main
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue