Type to search. Arrow keys to move, Enter to open, Esc to close.

All technologies

Incremental deploy

Uploading only the files that changed. The key question is change detection: FTP offers file size and modification time, but no content hash.

Project requirement

Upload static sites over FTP to shared hosting without re-sending every file after each build.

Technical question

How can an upload tool tell which files really changed, when a rebuild rewrites every file?

Validation

A second build without source changes reports no changes; tests cover the sync, the manifest diff and partial builds.

Decision

Keep the modification time of unchanged files, so 'overwrite if newer' tools work, and write a hash-based change list as a second check.

Modification time alone fails when the build rewrites everything; size alone fails when a same-length version string changes.

Deleting on the server needs an exclude list, because the server may hold files that are not part of the build.

Implementations by language

Python

The build syncs into the output folder by comparing content, writes a SHA-256 manifest and a per-domain list of files to upload and delete.

  • A file is rewritten only if its size or bytes differ, so unchanged files keep their modification time.
  • Manifest entries of domains that were not rebuilt are kept, so building one site does not reset the others.

Used by projects

Related research