equal
deleted
inserted
replaced
443 # If the action has been marked with a preserve attribute, and |
443 # If the action has been marked with a preserve attribute, and |
444 # the file exists and has a content hash different from what the |
444 # the file exists and has a content hash different from what the |
445 # system expected it to be, then we preserve the original file |
445 # system expected it to be, then we preserve the original file |
446 # in some way, depending on the value of preserve. If the |
446 # in some way, depending on the value of preserve. If the |
447 # action is an overlay, then we always overwrite. |
447 # action is an overlay, then we always overwrite. |
448 overlay = self.attrs.get("overlay", "false") == "true" |
448 overlay = self.attrs.get("overlay") == "true" |
449 if is_file and not overlay: |
449 if is_file and not overlay: |
450 chash, cdata = misc.get_data_digest(final_path) |
450 chash, cdata = misc.get_data_digest(final_path) |
451 if not orig or chash != orig.hash: |
451 if not orig or chash != orig.hash: |
452 if pres_type in ("renameold", "renamenew"): |
452 if pres_type in ("renameold", "renamenew"): |
453 return pres_type |
453 return pres_type |