zaw icon indicating copy to clipboard operation
zaw copied to clipboard

zaw-action:2: number expected

Open martin-hoger opened this issue 6 years ago • 2 comments

First of all, thank you for the very nice widget. I have been using it already for some years.

Currently I have started to get following error when I press Enter on the selected item:

zaw-action:2: number expected

I have also found out that if I comment out styles in zaw-action(), everything gets executed as before:

#local -a styles=(default alt)

Do I need to add some style settings to make it work?

martin-hoger avatar Mar 05 '18 12:03 martin-hoger

Thanks report.

I guess your zsh version is old. Could you please test the following code?

local -a ary=(a b); echo $ary

It returns number expected error for older zsh while current version returns a b. We should split this line to support old zsh:

local -a styles
styles=(default alt)

termoshtt avatar Mar 06 '18 05:03 termoshtt

Thank you. Yes, you are right. The old version (5.0.7) would not execute it. I have tried it on another computer, zsh version 5.2, works like charm.

martin-hoger avatar Mar 06 '18 07:03 martin-hoger