MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / print_entries

Method print_entries

atomic-cli/src/commands/log/command.rs:407–418  ·  view source on GitHub ↗

Print entries in the configured format. # Arguments `entries` - History entries to print

(&self, entries: &[HistoryEntry])

Source from the content-addressed store, hash-verified

405 ///
406 /// * `entries` - History entries to print
407 fn print_entries(&self, entries: &[HistoryEntry]) {
408 let hash_length = self.get_hash_length();
409
410 let output = match self.format {
411 LogFormat::Default => self.format_default(entries, hash_length),
412 LogFormat::Short => self.format_short(entries, hash_length),
413 LogFormat::Oneline => self.format_oneline(entries, hash_length),
414 LogFormat::Json => self.format_json(entries),
415 };
416
417 print!("{}", output);
418 }
419
420 /// Print empty history message.
421 ///

Callers 1

runMethod · 0.80

Calls 5

format_onelineMethod · 0.80
get_hash_lengthMethod · 0.45
format_defaultMethod · 0.45
format_shortMethod · 0.45
format_jsonMethod · 0.45

Tested by

no test coverage detected