Thread (6 messages) 6 messages, 4 authors, 2018-05-05

Re: [RFC PATCH] checkout: Force matching mtime between files

From: Robin H. Johnson <hidden>
Date: 2018-04-25 06:58:56

On Fri, Apr 13, 2018 at 07:01:29PM +0200, Michał Górny wrote:
quoted hunk ↗ jump to hunk
--- a/entry.c
+++ b/entry.c
@@ -411,6 +411,7 @@ int checkout_entry(struct cache_entry *ce,
 {
 	static struct strbuf path = STRBUF_INIT;
 	struct stat st;
+	int ret;
 
 	if (topath)
 		return write_entry(ce, topath, state, 1);
mgorny: Should the topath case trigger utime as well?

Other questions:
- Would there be be any value in hoisting the utime change into
  write_entry's finish block rather than having it in checkout_entry?
- Should mtimes on directories be set if the directory is explicitly
  created?
- Maybe using futimens on supported platforms?

-- 
Robin Hugh Johnson
Gentoo Linux: Dev, Infra Lead, Foundation Treasurer
E-Mail   : robbat2@gentoo.org
GnuPG FP : 11ACBA4F 4778E3F6 E4EDF38E B27B944E 34884E85
GnuPG FP : 7D0B3CEB E9B85B1F 825BCECF EE05E6F6 A48F6136

Attachments

Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help