The invention belongs to the technical field of
computer software and
data processing, and provides a differential upgrading method for a compressed file, which is divided into a differential stage and a reduction stage: the differential stage: decompressing an original compressed
package of a starting version and an original compressed
package of a target version; unifying and standardizing file permissions for the two decompressed folders, and modifying, accessing and changing timestamps; re-compressing to generate a first new compressed file and a second new compressed file with
byte-level certainty; generating a first difference file based on the difference between the standardized
directory structure and the content; comparing the second new compressed file with the original compressed file of the target version, performing lossless analysis on the ZIP
metadata, and performing structured modeling on difference information to generate a second difference file; in the reduction stage,
standardization, first differential reduction, recompression and second differential driven
metadata accurate reconstruction are sequentially executed, and a result completely consistent with the
byte level of the original compressed file of the target version is output. According to the method, the differential
compression ratio and the restoration fidelity can be improved.