Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

PATCH: Add NEWS entry for array zipping operators.



Here's the blurb for :^ and :^^. I noticed that previous news entries
have an indented bullet format but the latest section doesn't, does
anyone care either way?

---
 NEWS | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/NEWS b/NEWS
index cde1e7c..c21149a 100644
--- a/NEWS
+++ b/NEWS
@@ -78,6 +78,11 @@ second; by default milliseconds are shown, but the number of digits may
 be indicated from 1 to 6, e.g. "%6.".  (Note this is part of the
 extensions to strftime() formats rather than basic prompt escapes.)
 
+The operators :^ and :^^ in parameter substitution allow for array
+zipping in the form ${name:^array}. With the :^ operator, all entries
+in $name and $array will be output in alternating order with the
+longer array trimmed, whereas the :^^ operator repeats the shorter
+array enough to match the longer array.
 
 Changes between 4.2 and 5.0.0
 -----------------------------
-- 
1.9.0



Messages sorted by: Reverse Date, Date, Thread, Author