Skip to content

Commit

Permalink
fix(install): πŸ› Patch for @zi-register-annex (#242)
Browse files Browse the repository at this point in the history
  • Loading branch information
ss-o authored Nov 15, 2022
1 parent 04310b2 commit c410f7d
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions zi.zsh
Original file line number Diff line number Diff line change
Expand Up @@ -999,7 +999,7 @@ builtin setopt noaliases
# FUNCTION: .zi-register-plugin. [[[
# Adds the plugin to ZI_REGISTERED_PLUGINS array and to the
# zsh_loaded_plugins array (managed according to the plugin standard:
# https://z.digitalclouds.dev/community/zsh_plugin_standard).
# https://wiki.zshell.dev/community/zsh_plugin_standard).
.zi-register-plugin() {
local uspl2="$1" mode="$2" teleid="$3"
integer ret=0
Expand Down Expand Up @@ -1098,6 +1098,8 @@ builtin setopt noaliases
# FUNCTION: @zi-register-annex. [[[
# Registers the z-annex inside Zi – i.e. an Zi extension
@zi-register-annex() {
builtin emulate -LR zsh ${=${options[xtrace]:#off}:+-o xtrace}
builtin setopt no_bang_hist
local name="$1" type="$2" handler="$3" helphandler="$4" icemods="$5" key="z-annex ${(q)2}"
ZI_EXTS[seqno]=$(( ${ZI_EXTS[seqno]:-0} + 1 ))
ZI_EXTS[$key${${(M)type#hook:}:+ ${ZI_EXTS[seqno]}}]="${ZI_EXTS[seqno]} z-annex-data: ${(q)name} ${(q)type} ${(q)handler} ${(q)helphandler} ${(q)icemods}"
Expand All @@ -1119,7 +1121,7 @@ builtin setopt noaliases
} # ]]]
# FUNCTION: @zsh-plugin-run-on-update. [[[
# The Plugin Standard required mechanism, see:
# https://z.digitalclouds.dev/community/zsh_plugin_standard
# https://wiki.zshell.dev/community/zsh_plugin_standard
@zsh-plugin-run-on-unload() {
ICE[ps-on-unload]="${(j.; .)@}"
.zi-pack-ice "$id_as" ""
Expand Down

0 comments on commit c410f7d

Please sign in to comment.