Change summary
cmd/area/show.go | 6 ++++--
cmd/goal/show.go | 5 +++--
2 files changed, 7 insertions(+), 4 deletions(-)
Detailed changes
@@ -8,6 +8,7 @@ import (
"fmt"
"git.secluded.site/lune/internal/client"
+ "git.secluded.site/lune/internal/completion"
"git.secluded.site/lune/internal/config"
"git.secluded.site/lune/internal/deeplink"
"git.secluded.site/lune/internal/stats"
@@ -22,8 +23,9 @@ var ShowCmd = &cobra.Command{
Long: `Show detailed information for a configured area.
Displays the area's name, ID, deeplink, goals, and uncompleted task count.`,
- Args: cobra.ExactArgs(1),
- RunE: runShow,
+ Args: cobra.ExactArgs(1),
+ ValidArgsFunction: completion.Areas,
+ RunE: runShow,
}
func runShow(cmd *cobra.Command, args []string) error {
@@ -29,8 +29,9 @@ var ShowCmd = &cobra.Command{
If the goal key exists in multiple areas, use --area to disambiguate.
Displays the goal's name, ID, deeplink, and uncompleted task count.`,
- Args: cobra.ExactArgs(1),
- RunE: runShow,
+ Args: cobra.ExactArgs(1),
+ ValidArgsFunction: completion.Goals,
+ RunE: runShow,
}
func init() {