split global
This commit is contained in:
parent
c72676ccac
commit
31f67370ed
51
global.zsh
51
global.zsh
@ -13,51 +13,6 @@ if [[ -z $globaldots_path ]]; then
|
|||||||
echo 'functions require $globaldots_path to be set!'
|
echo 'functions require $globaldots_path to be set!'
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# ZCONFIG
|
autoload global_path_expand global_fpath_expand global_set_useropts \
|
||||||
|
global_configure global_config_setup global_boot
|
||||||
## stuff for global dotfiles
|
fpath+=(${zshlibs_install}/global)
|
||||||
|
|
||||||
function global_path_expand()
|
|
||||||
{
|
|
||||||
local bin_base=${globaldots_path}/bin
|
|
||||||
for pathnew in ${*}; do
|
|
||||||
zshlibs_path_add "${bin_base}/${pathnew}"
|
|
||||||
done;
|
|
||||||
}
|
|
||||||
|
|
||||||
function global_fpath_expand()
|
|
||||||
{
|
|
||||||
local bin_base=${globaldots_path}/bin
|
|
||||||
for pathnew in ${*}; do
|
|
||||||
zshlibs_fpath_add "${bin_base}/${pathnew}"
|
|
||||||
done;
|
|
||||||
}
|
|
||||||
|
|
||||||
function global_set_useropts()
|
|
||||||
{
|
|
||||||
typeset -a -g path_extra
|
|
||||||
}
|
|
||||||
|
|
||||||
function global_configure()
|
|
||||||
{
|
|
||||||
typeset -a -g path_extra
|
|
||||||
}
|
|
||||||
|
|
||||||
function global_config_setup()
|
|
||||||
{
|
|
||||||
zshlibs_log global "expanding path with '$path_extra'"
|
|
||||||
global_path_expand $path_extra
|
|
||||||
zshlibs_log global "expanding fpath with '$fpath_extra'"
|
|
||||||
global_fpath_expand vanilla
|
|
||||||
zshlibs_log global "done loading noninteractive config"
|
|
||||||
}
|
|
||||||
|
|
||||||
function global_boot()
|
|
||||||
{
|
|
||||||
global_configure
|
|
||||||
global_config_setup
|
|
||||||
}
|
|
||||||
|
|
||||||
## normal functions
|
|
||||||
|
|
||||||
|
|
||||||
|
5
global/global_boot
Normal file
5
global/global_boot
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
function global_boot()
|
||||||
|
{
|
||||||
|
global_configure
|
||||||
|
global_config_setup
|
||||||
|
}
|
8
global/global_config_setup
Normal file
8
global/global_config_setup
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
function global_config_setup()
|
||||||
|
{
|
||||||
|
zshlibs_log global "expanding path with '$path_extra'"
|
||||||
|
global_path_expand $path_extra
|
||||||
|
zshlibs_log global "expanding fpath with '$fpath_extra'"
|
||||||
|
global_fpath_expand vanilla
|
||||||
|
zshlibs_log global "done loading noninteractive config"
|
||||||
|
}
|
4
global/global_configure
Normal file
4
global/global_configure
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
function global_configure()
|
||||||
|
{
|
||||||
|
typeset -a -g path_extra
|
||||||
|
}
|
7
global/global_fpath_expand
Normal file
7
global/global_fpath_expand
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
function global_fpath_expand()
|
||||||
|
{
|
||||||
|
local bin_base=${globaldots_path}/bin
|
||||||
|
for pathnew in ${*}; do
|
||||||
|
zshlibs_fpath_add "${bin_base}/${pathnew}"
|
||||||
|
done;
|
||||||
|
}
|
7
global/global_path_expand
Normal file
7
global/global_path_expand
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
function global_path_expand()
|
||||||
|
{
|
||||||
|
local bin_base=${globaldots_path}/bin
|
||||||
|
for pathnew in ${*}; do
|
||||||
|
zshlibs_path_add "${bin_base}/${pathnew}"
|
||||||
|
done;
|
||||||
|
}
|
4
global/global_set_useropts
Normal file
4
global/global_set_useropts
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
function global_set_useropts()
|
||||||
|
{
|
||||||
|
typeset -a -g path_extra
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user