taskwarrior
taskwarrior copied to clipboard
Possible UDA values on validation error would be nice
Given:
[λ] /tmp/scratch >_ task --version
2.6.2
and
# .taskrc
uda.urgent.type=string
uda.urgent.label=Urgent
uda.urgent.values=T,F
when
task add tost urgency:ble
then
The 'urgency' attribute does not allow a value of 'ble'.
What I'd like to see are the possible values, so that I don't have to go back to .taskrc. For example I have defined an UDA called netz with possible values T, F, Plan and Maybe. Sometimes I'd put in Prepare instead of Plan. Brainfart. I could be reminded of possible correct values without a mental context switch. So the error message I'd love to see would be:
The 'urgency' attribute does not allow a value of 'ble'. Possible values: T, F.
Of course that'd only work for string, but maybe an example could be provided for other types (like a properly formed date). Whatever, I only care about string UDAs, since I don't use the other types yet.
This is a nice suggestion!