(deps commandDeps)
| 943 | } |
| 944 | |
| 945 | func newMemoryDailyListCommand(deps commandDeps) *cobra.Command { |
| 946 | var flags memorySelectorFlags |
| 947 | |
| 948 | cmd := &cobra.Command{ |
| 949 | Use: "ls", |
| 950 | Short: "List Memory v2 daily operation logs", |
| 951 | Args: cobra.NoArgs, |
| 952 | RunE: func(cmd *cobra.Command, _ []string) error { |
| 953 | client, err := clientFromDeps(deps) |
| 954 | if err != nil { |
| 955 | return err |
| 956 | } |
| 957 | selector, err := resolveMemorySelectorFlags(deps, flags, memorySelectorOptions{DefaultWorkspace: true}) |
| 958 | if err != nil { |
| 959 | return err |
| 960 | } |
| 961 | response, err := client.ListMemoryDailyLogs(cmd.Context(), selector) |
| 962 | if err != nil { |
| 963 | return err |
| 964 | } |
| 965 | return writeCommandOutput(cmd, memoryObjectBundle("Memory Daily Logs", response)) |
| 966 | }, |
| 967 | } |
| 968 | addMemorySelectorFlags(cmd, &flags) |
| 969 | return cmd |
| 970 | } |
| 971 | |
| 972 | func newMemoryExtractorCommand(deps commandDeps) *cobra.Command { |
| 973 | cmd := &cobra.Command{ |
no test coverage detected