[Scummvm-git-logs] scummvm master -> 27731fafd04315be57dee1eb3f441d4b9d4b15e7
sev-
noreply at scummvm.org
Mon Jun 30 14:25:12 UTC 2025
This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://api.github.com/repos/scummvm/scummvm .
Summary:
27731fafd0 DEVTOOLS: COMPANION: Fix directory timestamps _after_ writing to them
Commit: 27731fafd04315be57dee1eb3f441d4b9d4b15e7
https://github.com/scummvm/scummvm/commit/27731fafd04315be57dee1eb3f441d4b9d4b15e7
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2025-06-30T16:25:02+02:00
Commit Message:
DEVTOOLS: COMPANION: Fix directory timestamps _after_ writing to them
Thanks to LePhilousophe for pointing this out
Changed paths:
devtools/dumper-companion.py
diff --git a/devtools/dumper-companion.py b/devtools/dumper-companion.py
index a275f551972..0d0b20b0f0e 100755
--- a/devtools/dumper-companion.py
+++ b/devtools/dumper-companion.py
@@ -547,12 +547,6 @@ def extract_volume_iso(args: argparse.Namespace) -> None:
if not dryrun:
os.makedirs(joined_path, exist_ok=True)
- arg[path_type] = os.path.join(dirname, dir)
- rec = iso.get_record(**arg).date
- stamp = datetime(rec.years_since_1900 + 1900, rec.month, rec.day_of_month,
- rec.hour - rec.gmtoffset, rec.minute, rec.second, tzinfo=timezone.utc).timestamp()
- os.utime(joined_path, (stamp, stamp))
-
for file in filelist:
filename = file.split(";")[0]
iso_file_path = os.path.join(dirname, file)
@@ -576,6 +570,22 @@ def extract_volume_iso(args: argparse.Namespace) -> None:
os.utime(os.path.join(pwd, filename), (stamp, stamp))
+ print("Fixing directory timestamps...")
+
+ arg[path_type] = "/"
+ for dirname, dirlist, filelist in iso.walk(**arg):
+ pwd = output_dir + dirname
+ # Set the modified time for directories
+ for dir in dirlist:
+ joined_path = os.path.join(pwd, dir)
+ if not dryrun:
+ print(joined_path)
+ arg[path_type] = os.path.join(dirname, dir)
+ rec = iso.get_record(**arg).date
+ stamp = datetime(rec.years_since_1900 + 1900, rec.month, rec.day_of_month,
+ rec.hour - rec.gmtoffset, rec.minute, rec.second, tzinfo=timezone.utc).timestamp()
+ os.utime(joined_path, (stamp, stamp))
+
if dopunycode:
punyencode_dir(Path(output_dir))
iso.close()
More information about the Scummvm-git-logs
mailing list