From 5af50dd5795f93ab163383061c2404a712690096 Mon Sep 17 00:00:00 2001 From: CyberLeo Date: Mon, 15 Feb 2010 07:03:21 -0600 Subject: [PATCH] script/gentree: touch contents of scavenged .cpio.gz confpacks as well --- script/gentree | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/script/gentree b/script/gentree index 550768b..faf7313 100755 --- a/script/gentree +++ b/script/gentree @@ -256,6 +256,17 @@ do_custom() { ( cd "${base}/conf" && find . | egrep -v '^\./.*\.md_size$' | cpio -p --link "${sconf}/default" ) || chk # Make sure files in default are newer than the tagfile, so they will be caught by saveconfig find "${sconf}/default" -type f -print0 | xargs -0 touch + # If there are scavenged cpio.gz confpacks, touch their contents as well. + chk mkdir -p "${stage}/pack" + chk rm -Rf "${stage}/pack"/* + for file in "${sconf}/default"/*.cpio.gz + do + pack="$(basename "${file%%.cpio.gz}")" + zcat "${file}" | ( cd "${stage}/pack"; cpio -id ) || chk + find "${stage}/pack" -type f -print0 | xargs -0 touch + ( cd "${stage}/pack"; find . | cpio -o ) | gzip -9 > "${file}" + chk rm -Rf "${stage}/pack"/* + done } for step in ${sequence} -- 2.42.0