optimize the perf and support more features

This commit is contained in:
Lei Xue
2026-03-14 11:45:35 +08:00
parent 7e7ebacd9d
commit 00cfac3d24
56 changed files with 6340 additions and 1019 deletions

View File

@@ -93,6 +93,9 @@ func listTarget(cli *client.Client, opts api.TargetListOptions) error {
w := tabwriter.NewWriter(os.Stdout, 20, 1, 3, ' ', 0)
fmt.Fprintln(w, "TARGET NAME\tSTATE\tSESSIONS")
for _, tgt := range results {
if tgt == nil {
continue
}
status := "online"
if tgt.State == api.TargetReady {
status = "ready"