(cmd *cobra.Command, items []VaultRecord, now func() time.Time)
| 171 | } |
| 172 | |
| 173 | func writeVaultRecordsOutput(cmd *cobra.Command, items []VaultRecord, now func() time.Time) error { |
| 174 | mode, err := resolveOutputFormat(cmd) |
| 175 | if err != nil { |
| 176 | return err |
| 177 | } |
| 178 | if mode == OutputJSONL { |
| 179 | for _, item := range items { |
| 180 | if err := writeJSONLine(cmd, item); err != nil { |
| 181 | return err |
| 182 | } |
| 183 | } |
| 184 | return nil |
| 185 | } |
| 186 | return writeCommandOutput(cmd, vaultRecordsBundle(items, now)) |
| 187 | } |
| 188 | |
| 189 | func writeVaultRecordOutput(cmd *cobra.Command, item VaultRecord) error { |
| 190 | mode, err := resolveOutputFormat(cmd) |
no test coverage detected