From: lilydjwg <lilydjwg@gmail.com>
To: Mikael Magnusson <mikachu@gmail.com>
Cc: Zsh hackers list <zsh-workers@zsh.org>
Subject: Re: bad math expression error inside _pick_variant when running insert-all-matches for ls
Date: Tue, 29 Sep 2020 01:51:26 +0800 [thread overview]
Message-ID: <CABaaJjOTkGktqEfHy9Bvv7dRxpP6v-FMJQamvb1P3QPoZ0XuYQ@mail.gmail.com> (raw)
In-Reply-To: <CAHYJk3RAzZFJrtvj1HsAADgVyxAuCwyFFDRzn-vNeShdiexB-w@mail.gmail.com>
[-- Attachment #1: Type: text/plain, Size: 1082 bytes --]
I'm sorry I thought it came with zsh, but it turned out that I got it from
a zsh-users message. The code is
_insert_all_matches () {
setopt localoptions nullglob rcexpandparam extendedglob noshglob
unsetopt markdirs globsubst shwordsplit nounset ksharrays
compstate[insert]=all
compstate[old_list]=keep
_complete
}
zle -C insert-all-matches complete-word _insert_all_matches
This code has worked for me for a few years until today I noticed that it
didn't work well with ls.
Mikael Magnusson <mikachu@gmail.com> 于 2020年9月29日周二 00:30写道:
> On 9/28/20, lilydjwg <lilydjwg@gmail.com> wrote:
> > bindkey '^Xi' insert-all-matches
> >
> > And then type:
> >
> > ls ^Xi
> >
> > There is an error message:
> >
> > _pick_variant:19: bad math expression: operand expected at `|| 0 ) '
> >
> > I'm using zsh 5.8 on Arch Linux.
>
> You should either complain to the person who wrote insert-all-matches,
> or provide the code here, otherwise nobody has any chance to guess
> what's wrong.
>
> --
> Mikael Magnusson
>
[-- Attachment #2: Type: text/html, Size: 1841 bytes --]
next prev parent reply other threads:[~2020-09-28 17:52 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-09-28 15:39 lilydjwg
2020-09-28 16:30 ` Mikael Magnusson
2020-09-28 16:47 ` Peter Stephenson
2020-09-28 16:51 ` Peter Stephenson
2020-09-28 17:02 ` Roman Perepelitsa
2020-09-28 17:06 ` Peter Stephenson
2020-09-28 17:51 ` lilydjwg [this message]
2020-09-28 20:42 ` Bart Schaefer
2020-09-29 6:10 ` Oliver Kiddle
2020-09-29 14:59 ` lilydjwg
2020-10-04 17:11 ` Daniel Shahaf
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CABaaJjOTkGktqEfHy9Bvv7dRxpP6v-FMJQamvb1P3QPoZ0XuYQ@mail.gmail.com \
--to=lilydjwg@gmail.com \
--cc=mikachu@gmail.com \
--cc=zsh-workers@zsh.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/zsh/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).