Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Why does colors() not use %{ %}?
- X-seq: zsh-workers 25305
- From: "Richard Hartmann" <richih.mailinglist@xxxxxxxxx>
- To: "Zsh hackers list" <zsh-workers@xxxxxxxxxx>
- Subject: Why does colors() not use %{ %}?
- Date: Sat, 19 Jul 2008 02:23:05 +0200
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to :subject:mime-version:content-type:content-transfer-encoding :content-disposition; bh=mid2uN+I8V0oiv+5ZixDe/KAmmNztjkVDEBDwpAOmDE=; b=L1noEOCecqn2H3Z6RO232vFZv9WhbOoNv3XxHRyR/OOEpomr/GJZt8XUuvceo+57F2 v6fFmI+5+YMRk9gFlloXg5WOKk5CVgwmJ3LSqIkeVrh8BeY4Ql5aC7K9jAYCfOAzziCo xR9wNCpQf0yI0DzktI17aiK8g6JTno01EZMEs=
- Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:mime-version:content-type :content-transfer-encoding:content-disposition; b=lTQbcAX33JYQdwoF3DG04QSw6Q/Ncdm/T4z0NzGexaP56p5kwrWSRyXblN1u7Ki8mj I8kaFKZ3Onu6AS6oR943IcmBBvzry5DRAWUWTGbfT8K1xlWBrWrpZV2j0knvFTsF/4BV X2zauMxBnymBBFCcZj7KotemL266Uz6L8T2+I=
- Mailing-list: contact zsh-workers-help@xxxxxxxxxx; run by ezmlm
Hi all,
after a somewhat embarassing email to -users, I realized colors() does
not properly escape color codes in its variables. What is the reason
for this behaviour?
I see three possible fixes, if there is interest in such a thing:
1) Change the existing functions. This _might_ break existing stuff.
2) Introduce new associative arrays with similar names.
3) Create a second function, colors_escaped(), which can be loaded
either additionally or instead.
It is, of course, possible that there is a good reason for not escaping
the color codes. If that is the case, I would love to learn it :)
Thanks,
Richard
Messages sorted by:
Reverse Date,
Date,
Thread,
Author