From d0484b153aa5fa80c415f4025aef493eba167e12 Mon Sep 17 00:00:00 2001 From: Robin Jarry Date: Sat, 12 Oct 2024 00:21:46 +0200 Subject: completion: add command option descriptions Add `desc:""` struct field tags in all command arguments where it makes sense. The description values will be returned along with completion choices. Implements: https://todo.sr.ht/~rjarry/aerc/271 Signed-off-by: Robin Jarry Tested-by: Bojan Gabric Tested-by: Jason Cox Acked-by: Tim Culverhouse --- commands/msg/envelope.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'commands/msg/envelope.go') diff --git a/commands/msg/envelope.go b/commands/msg/envelope.go index 09e7fa19..d064e43c 100644 --- a/commands/msg/envelope.go +++ b/commands/msg/envelope.go @@ -14,8 +14,8 @@ import ( ) type Envelope struct { - Header bool `opt:"-h"` - Format string `opt:"-s" default:"%-20.20s: %s"` + Header bool `opt:"-h" desc:"Show all header fields."` + Format string `opt:"-s" default:"%-20.20s: %s" desc:"Format specifier."` } func init() { -- cgit