From: Stephane Chazelas <stephane@chazelas.org>
To: Peter Stephenson <p.w.stephenson@ntlworld.com>,
Zsh hackers list <zsh-workers@zsh.org>
Subject: Re: histsubstpattern in zmv
Date: Fri, 2 Jun 2023 16:29:32 +0100 [thread overview]
Message-ID: <20230602152932.ykoazfo5o6somi7w@chazelas.org> (raw)
In-Reply-To: <20230602150953.xr6ukng3oxsv2jpv@chazelas.org>
2023-06-02 16:09:53 +0100, Stephane Chazelas:
[...]
> May be worth applying the patch below today for future-proofing
$ grep -rnP '\$[~^=#]?([$!#?*@]|\w+)(\[[^]]*\])?:(?![aAceghlpPqQrstux])\w' Completion
Completion/Solaris/Command/_ipadm:139: proto_all_properties=( $^proto_all_properties:value:_ipadm_get_possible_values )
is more complete (accounts for the $# $!... special parameters
and $~var, $^var...) and finds that extra one.
I likely still forget some more.
diff --git a/Completion/Solaris/Command/_ipadm b/Completion/Solaris/Command/_ipadm
index 34d1eacba..c59fc8108 100644
--- a/Completion/Solaris/Command/_ipadm
+++ b/Completion/Solaris/Command/_ipadm
@@ -136,7 +136,7 @@ _ipadm() {
proto_icmp_properties=( "max_buf" "recv_buf" "send_buf" )
proto_all_properties=( $proto_ipv4_properties $proto_ipv6_properties $proto_tcp_properties
$proto_udp_properties $proto_sctp_properties $proto_icmp_properties )
- proto_all_properties=( $^proto_all_properties:value:_ipadm_get_possible_values )
+ proto_all_properties=( ${^proto_all_properties}:value:_ipadm_get_possible_values )
proto_propproperties=( "proto" "property" "perm" "current" "persistent" "default" "possible" )
> and a note in the manual that it's unwise to leave a parameter
> expansion un-braced if it's followed by a ":"?
[...]
unless the ksharrays option is enabled.
--
Stephane
next prev parent reply other threads:[~2023-06-02 15:29 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-06-01 18:35 Stephane Chazelas
2023-06-02 8:40 ` Peter Stephenson
2023-06-02 10:18 ` Peter Stephenson
2023-06-02 15:09 ` Stephane Chazelas
2023-06-02 15:29 ` Stephane Chazelas [this message]
2023-06-04 18:32 ` Peter Stephenson
2023-06-08 6:57 ` Jun T
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=20230602152932.ykoazfo5o6somi7w@chazelas.org \
--to=stephane@chazelas.org \
--cc=p.w.stephenson@ntlworld.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).