From: Bart Schaefer <schaefer@brasslantern.com>
To: zsh-workers@zsh.org
Subject: Re: Aliasing assignment-ish words (aliases[x=y]=z)
Date: Mon, 11 Jan 2016 23:44:29 -0800 [thread overview]
Message-ID: <160111234429.ZM6760@torch.brasslantern.com> (raw)
In-Reply-To: <20160110195030.GB1997@tarsus.local2>
On Jan 10, 7:50pm, Daniel Shahaf wrote:
}
} I thought we might want to have 'alias -L' handle LHSes with '=' in them
} specially: omit them from the output with a warning, or maybe fail hard
Yeah, that probably wouldn't be too difficult (I'd go with the warning).
} For what it's worth, the real-world use-case behind this thread is
} a z-sy-h user whose zshrc has an alias "aliases[=]='noglob ='" and
} a function literally named '='. (That alias works as expected, as
} does "aliases[=ls]='...'" even if EQUALS is set.)
Hm, it also ought to be possible to special case a word starting with
'=' (since it's not possible to alias the empty string to anything).
I find this interesting:
torch% alias '==foo'
zsh: bad assignment
"Bad assignment"?
next prev parent reply other threads:[~2016-01-12 7:44 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-01-01 0:37 Daniel Shahaf
2016-01-10 19:19 ` Bart Schaefer
2016-01-10 19:50 ` Daniel Shahaf
2016-01-12 7:44 ` Bart Schaefer [this message]
2016-01-13 0:57 ` Daniel Shahaf
2016-01-13 0:58 ` 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=160111234429.ZM6760@torch.brasslantern.com \
--to=schaefer@brasslantern.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).