🏡 index : ~doyle/packfile.git

author David Monroe <david.m.monroe@proton.me> 2023-06-21 19:00:16.0 +00:00:00
committer David Monroe <david.m.monroe@proton.me> 2023-06-21 19:00:32.0 +00:00:00
commit
ff0f94911cc69b6614e0885b02bce01f431209bb [patch]
tree
f8ccd44a1d62ff506b4d0db93b43731baf60a5f8
parent
235e7acc3dc3ea9f47aefbada237c9ead8b959fa
download
ff0f94911cc69b6614e0885b02bce01f431209bb.tar.gz

Always set commit/author time to epoch

If the contents of the tree have not changed, we don't want cargo update
to fetch anything. This requires the commit in the packfile to remain
stable.

Diff

 src/high_level.rs | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/high_level.rs b/src/high_level.rs
index b06a1e6..c49f165 100644
--- a/src/high_level.rs
+++ b/src/high_level.rs
@@ -99,7 +99,7 @@ impl GitRepository {
        let commit_user = CommitUserInfo {
            name,
            email,
            time: time::OffsetDateTime::now_utc(),
            time: time::OffsetDateTime::UNIX_EPOCH,
        };

        let commit = PackFileEntry::Commit(Commit {