Skip to main content

uniondiff - Directory difference calculator

uniondiff is a simple tool for calculating the directory difference between two directories or archives. uniondiff performs the calculation below:

upper = merged - lower

This tool acts as the inverse union mount file systems. Whereas typically you combine a lower and upper directory to produce a merged directory, uniondiff takes as input the merged directory and subtracts out the lower directory to produce the upper directory. In particular, the resulting output can be mounted as the upper directory along with the lower to produce the original merged directory.

uniondiff is intended for use with low level file system tools (e.g. container systems) or for simply storing diffs of directories. Note that this tool does not store compact diffs of individual files; a file will appear in full in the diff iff its content or metadata has changed between the merged and lower operands.

Installation

uniondiff can be installed through pip. This installs both the uniondiff CLI utility and the uniondiff Python library.

pip install uniondiff

uniondiff is supported and tested on Python 3.11-3.15

Examples

Compute the directory difference between the directory "data-day10" and "data-day9". By default the output will be written as a tar file.

uniondiff data-day10 data-day9 > diff.tar

uniondiff can also write directly to the file system. Note that it will ignore ownership changes unless you also pass the --preserve-owners flag.

uniondiff data-day10 data-day9 --output-type file -o diff

You can also use tar archives as the input paths.

uniondiff data-day10.tar data-day9.tgz > diff.tar

Contributing

If you want to contribute to uniondiff, you can do so by creating a pull request. lease make sure to include a detailed description of the changes you're proposing.

Metadata

Release files for uniondiff 0.1.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for uniondiff 0.1.2
File Size Uploaded Provenance
uniondiff-0.1.2.tar.gz 19.8 kB With provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for uniondiff 0.1.2
File Interpreter ABI Platform
uniondiff-0.1.2-py3-none-any.whl Python 3 none any Details

Total release size: 40.0 kB

Release files / uniondiff-0.1.2.tar.gz

Download URL uniondiff-0.1.2.tar.gz
Size 19.8 kB
Tags Source
SHA-256 checksum
How to use checksums
f6e5750fff4b57d44b962bbf1eff0ff0830f8757cc78e3b2427bf57d9b1ed4bc
BLAKE2b-256 checksum
How to use checksums
c27f718600e184f4c1f58fd56e7e3f3da8beb3ba6baa8b9d3d2b6a9011ab3a22
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 20, 2026.

Transparency log

Release files / uniondiff-0.1.2-py3-none-any.whl

Download URL uniondiff-0.1.2-py3-none-any.whl
Size 20.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
3cadf5e384a0093e041c3c16d3eb3c753fa16ad2f22fa22c5b60744f09eaa764
BLAKE2b-256 checksum
How to use checksums
812d67d66bd84382d409e4e5da964528583a1bc99f9d93a974b7a1f648d8fbd0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 20, 2026.

Transparency log

Security for uniondiff 0.1.2

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 2 files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for uniondiff-0.1.2.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 20, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page