-
Notifications
You must be signed in to change notification settings - Fork 183
Open
Labels
enhancementNew feature or requestNew feature or request
Description
Is your feature request related to a problem? Please describe.
This is probably nitpicking enhancement rather than a feature request or a bug.
I note that in zimfw.zsh, paths with ${HOME} values are replaced with the variable names in the generated ${ZIM_HOME}/init.sh. But it looks like in most of the cases, replacing ${ZIM_HOME} is probably more appropriate.
Line 62 in 8ea4419
| print -R 'if [[ -e ${ZIM_CONFIG_FILE:-${ZDOTDIR:-${HOME}}/.zimrc} ]] zimfw() { source '${${(qqq)__ZIMFW_FILE}/${HOME}/\${HOME}}' "${@}" }' |
zimfw.zsh is in ${ZIM_HOME} by default.
Line 78 in 8ea4419
| if (( ${#_zfpaths} )) print -R 'fpath=('${${(qqq)${_zfpaths#${~zpre}}:a}/${HOME}/\${HOME}}' ${fpath})' |
Downloaded modules are likely to be in
${ZIM_HOME}, unless a local module is used.
Line 374 in 8ea4419
| zcmds=(${zcmds//${HOME}/\${HOME}}) |
Downloaded modules are likely to be in
${ZIM_HOME}, unless a local module is used.
Describe the solution you'd like
For example, in the last case, instead of the following.
zcmds=(${zcmds//${HOME}/\${HOME}})
Use this so that cases for either ${ZIM_HOME} or ${HOME} will be handled.
zcmds=(${${zcmds//${ZIM_HOME}/\${ZIM_HOME}}//${HOME}/\${HOME}})
I have tried it on my ${fpath} locally and it works as expected.
This is a minor suggestion. I can make a PR if it is agreeable.
Describe alternatives you've considered
NA.
Additional context
No response
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request