Add per-user zsh script loading
This commit is contained in:
19
sh/load.sh
19
sh/load.sh
@ -1,6 +1,19 @@
|
||||
TOOLKIT=/etc/toolkit
|
||||
|
||||
# Sources custom shell scripts
|
||||
for sh in ${TOOLKIT}/sh/custom/*.sh; do
|
||||
load_scripts_in_dir() {
|
||||
for sh in ${TOOLKIT}/sh/custom/*.sh; do
|
||||
test -r "$sh" && . "$sh"
|
||||
done
|
||||
done
|
||||
}
|
||||
|
||||
create_dir_if_not_exists() {
|
||||
if [[ ! -d $1 ]]; then
|
||||
mkdir -p $1
|
||||
fi
|
||||
}
|
||||
|
||||
# Load custom scripts (aliases, variables, etc...)
|
||||
load_scripts_in_dir $TOOLKIT/sh/custom_scripts
|
||||
|
||||
# Scripts ran to modify existing toolkit updates
|
||||
load_scripts_in_dir $TOOLKIT/sh/patch_scripts
|
||||
|
Reference in New Issue
Block a user