File tree Expand file tree Collapse file tree 1 file changed +4
-7
lines changed
Expand file tree Collapse file tree 1 file changed +4
-7
lines changed Original file line number Diff line number Diff line change @@ -88,13 +88,10 @@ for installed_package in ${installed_packages}; do
8888 log " * Caching ${package_name} to ${cache_filepath} ..."
8989
9090 # Pipe all package files (no folders) and installation control data to Tar.
91- { dpkg -L " ${package_name} " \
92- & get_install_script_filepath " " " ${package_name} " " preinst" \
93- & get_install_script_filepath " " " ${package_name} " " postinst" ; } |
94- while IFS= read -r f; do test -f " ${f} " -o -L " ${f} " && get_tar_relpath " ${f} " ; done |
95- # Single quotes ensure literals like backslash get captured. Use \0 to avoid field separation.
96- awk -F" \0" ' {print "\x27"$1"\x27"}' |
97- sudo xargs tar -cf " ${cache_filepath} " -C /
91+ tar -cf " ${cache_filepath} " -C / --verbatim-files-from --files-from <( { dpkg -L " ${package_name} " &&
92+ get_install_script_filepath " " " ${package_name} " " preinst" &&
93+ get_install_script_filepath " " " ${package_name} " " postinst" ; } |
94+ while IFS= read -r f; do test -f " ${f} " -o -L " ${f} " && get_tar_relpath " ${f} " ; done )
9895
9996 log " done (compressed size $( du -h " ${cache_filepath} " | cut -f1) )."
10097 fi
You can’t perform that action at this time.
0 commit comments