MCPcopy Create free account
hub / github.com/douglance/devsql / format_git_time

Function format_git_time

crates/vcsql/src/providers/reflog.rs:128–135  ·  view source on GitHub ↗
(time: git2::Time)

Source from the content-addressed store, hash-verified

126}
127
128fn format_git_time(time: git2::Time) -> String {
129 let timestamp = time.seconds();
130 if let Some(dt) = Utc.timestamp_opt(timestamp, 0).single() {
131 dt.format("%Y-%m-%d %H:%M:%S").to_string()
132 } else {
133 timestamp.to_string()
134 }
135}

Callers 1

populateMethod · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected