Skip to content

Commit

Permalink
ZPWR_EXPAND set after shell init
Browse files Browse the repository at this point in the history
  • Loading branch information
MenkeTechnologies committed Feb 4, 2022
1 parent 58a08ff commit 1a3de6f
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions zpwrExpandLib.zsh
Original file line number Diff line number Diff line change
Expand Up @@ -287,6 +287,10 @@ function zpwrExpandSupernaturalSpace() {
zpwrExpandParseWords "$LBUFFER"

if [[ $triggerKey == "${ZPWR_VARS[SPACE_KEY]}" ]]; then
if [[ $ZPWR_EXPAND == false ]]; then
zle self-insert
return
fi
if [[ $ZPWR_CORRECT == true ]]; then
zpwrExpandCorrectWord
if [[ $ZPWR_VARS[foundIncorrect] = true && $ZPWR_CORRECT_EXPAND = true ]]; then
Expand All @@ -301,6 +305,9 @@ function zpwrExpandSupernaturalSpace() {
fi

else
if [[ $ZPWR_EXPAND == false ]]; then
return
fi
zpwrExpandRegexMatchOnCommandPosition
fi

Expand Down

0 comments on commit 1a3de6f

Please sign in to comment.