Skip to content

Commit d25305b

Browse files
committed
adds a timestamp file in the fingerprint folder
1 parent bb8bb0d commit d25305b

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/cargo/core/compiler/fingerprint.rs

+4
Original file line numberDiff line numberDiff line change
@@ -681,6 +681,10 @@ pub fn dep_info_loc<'a, 'cfg>(cx: &mut Context<'a, 'cfg>, unit: &Unit<'a>) -> Pa
681681

682682
fn compare_old_fingerprint(loc: &Path, new_fingerprint: &Fingerprint) -> CargoResult<()> {
683683
let old_fingerprint_short = paths::read(loc)?;
684+
let _ = paths::write(
685+
&loc.with_file_name("last-used.timestamp"),
686+
b"This file has an mtime of when cargo last used this fingerprint.",
687+
);
684688
let new_hash = new_fingerprint.hash();
685689

686690
if util::to_hex(new_hash) == old_fingerprint_short {

0 commit comments

Comments
 (0)