Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: PATCH: list units in brackets at the end of completion group descriptions
- X-seq: zsh-workers 49318
- From: "Daniel Shahaf" <d.s@xxxxxxxxxxxxxxxxxx>
- To: zsh-workers@xxxxxxx
- Subject: Re: PATCH: list units in brackets at the end of completion group descriptions
- Date: Fri, 27 Aug 2021 12:10:53 +0000
- Archived-at: <https://zsh.org/workers/49318>
- In-reply-to: <73806-1630065135.858692@atah.qJX1.Jyyu>
- List-id: <zsh-workers.zsh.org>
- References: <73806-1630065135.858692@atah.qJX1.Jyyu>
Oliver Kiddle wrote on Fri, 27 Aug 2021 11:52 +00:00:
> There might be some more useful way we might indicate where suffixes can
> be appended to a value to denote units. Completing them after a number
> doesn't really make the options clear before a number has been entered.
> Perhaps an initial slash, e.g. 'timeout (seconds) [5] /ms /us /ns'
This design first says "Input a value in seconds", then the default
value, then goes back to say that other units are possible.
I think we should try for a design with more locality in the provision
of information. For instance, assuming the default unit may also be
specified explicitly:
timeout [5 = 5s]
# This intends to communicate that both «5» and «5s» are valid inputs, and equivalent.
timeout [5] ; hr/[s]/ms/us/ns
# Indicate the default value and default unit separately, indicating all units in a group
I'm sure there are better options than these.
Cheers,
Daniel
Messages sorted by:
Reverse Date,
Date,
Thread,
Author