You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Generate the integrity file which will contain all the files and their hashes.
Check if the file mode is either: edit/replace, delete, add, add-dir, etc.
To do this, compare the last changeset against the content folder and if one of the files isn't there, mark as deleted.
Deletion is all that matters.
Keep track of which folders were removed / added, again, check backwards with the integrity.xml file...
Updating (unrelated to this project):
Check if there's a caches.xml locally
If there is:
Read from the caches.xml on the server and see if our version id is lower than the one on the server.
If it's lower:
Download the new changeset.
Compare our last local hashes (from the previous update, duh) with the ones on the new change set (but only if it has been updated before, otherwise, check with the downloaded integrity.xml file)
Update appropriately
Otherwise
Just download everything since it's a fresh directory or they deleted the changeset and we can't trust it
Place / replace the integrity file in the changesets folder.
Checking integrity:
Open the integrity file.
Put all the hashes and file paths in a list.
Compare hashes file by file recursively.
If one of them is different, re-download from the server.
About
A multi-purpose update builder that compares file hashes and generates changesets.