Fix _zimfw_build_login_init
Pattern must match from the beginning (`##`). Also don't quote ${ZIM_HOME}. We don't want to have an array like ('${ZIM_HOME}' '/path/to/zim_home'), so it needs to be unquoted for the uniqueness to work.
This commit is contained in:
parent
9b02b41f47
commit
1e4d1e784d
2 changed files with 5 additions and 3 deletions
|
@ -1,5 +1,6 @@
|
||||||
_zimfw_build_login_init() {
|
_zimfw_build_login_init() {
|
||||||
local -Ur zscriptdirs=('${ZIM_HOME}' ${${_zdirs%%${ZIM_HOME}/*}:A})
|
# Array with unique dirs. ${ZIM_HOME} or any subdirectory should only occur once.
|
||||||
|
local -Ur zscriptdirs=(${ZIM_HOME} ${${_zdirs##${ZIM_HOME}/*}:A})
|
||||||
local -r zscriptglob=("${^zscriptdirs[@]}/(^*test*/)#*.zsh(|-theme)(N-.)")
|
local -r zscriptglob=("${^zscriptdirs[@]}/(^*test*/)#*.zsh(|-theme)(N-.)")
|
||||||
local -r ztarget=${ZIM_HOME}/login_init.zsh
|
local -r ztarget=${ZIM_HOME}/login_init.zsh
|
||||||
_zimfw_mv =(
|
_zimfw_mv =(
|
||||||
|
|
|
@ -65,7 +65,8 @@ _zimfw_build_init() {
|
||||||
}
|
}
|
||||||
|
|
||||||
_zimfw_build_login_init() {
|
_zimfw_build_login_init() {
|
||||||
local -Ur zscriptdirs=('${ZIM_HOME}' ${${_zdirs%%${ZIM_HOME}/*}:A})
|
# Array with unique dirs. ${ZIM_HOME} or any subdirectory should only occur once.
|
||||||
|
local -Ur zscriptdirs=(${ZIM_HOME} ${${_zdirs##${ZIM_HOME}/*}:A})
|
||||||
local -r zscriptglob=("${^zscriptdirs[@]}/(^*test*/)#*.zsh(|-theme)(N-.)")
|
local -r zscriptglob=("${^zscriptdirs[@]}/(^*test*/)#*.zsh(|-theme)(N-.)")
|
||||||
local -r ztarget=${ZIM_HOME}/login_init.zsh
|
local -r ztarget=${ZIM_HOME}/login_init.zsh
|
||||||
_zimfw_mv =(
|
_zimfw_mv =(
|
||||||
|
@ -312,7 +313,7 @@ _zimfw_compile() {
|
||||||
}
|
}
|
||||||
|
|
||||||
_zimfw_info() {
|
_zimfw_info() {
|
||||||
print -R 'zimfw version: '${_zversion}' (previous commit is 1fd8961)'
|
print -R 'zimfw version: '${_zversion}' (previous commit is 9b02b41)'
|
||||||
print -R 'ZIM_HOME: '${ZIM_HOME}
|
print -R 'ZIM_HOME: '${ZIM_HOME}
|
||||||
print -R 'Zsh version: '${ZSH_VERSION}
|
print -R 'Zsh version: '${ZSH_VERSION}
|
||||||
print -R 'System info: '$(command uname -a)
|
print -R 'System info: '$(command uname -a)
|
||||||
|
|
Loading…
Reference in a new issue