Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Utility to produce a difference between two directories suitable for union filesystems

License

NotificationsYou must be signed in to change notification settings

msg555/uniondiff

Repository files navigation

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

upper = merged - lower

This tool acts as the inverseunion mountfile systems. Whereas typically you combine alower andupper directory toproduce amerged directory,uniondiff takes as input themerged directoryand subtracts out thelower directory to produce theupper directory. Inparticular, the resulting output can be mounted as theupper directoryalong with thelower to produce the originalmerged directory.

uniondiff is intended for use with low level file system tools (e.g. containersystems) or for simply storing diffs of directories. Note that this tooldoesnot store compact diffs of individual files; a file will appear in full in thediff iff its content or metadata has changed between themerged andloweroperands.

Installation

uniondiff can be installed throughpip. This installs both theuniondiffCLI utility and theuniondiff Python library.

pip install uniondiff

uniondiff is supported and tested on Python 3.8-3.12

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 ignoreownership 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 touniondiff, you can do so by creating a pull request.lease make sure to include a detailed description of the changes you're proposing.

About

Utility to produce a difference between two directories suitable for union filesystems

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

[8]ページ先頭

©2009-2025 Movatter.jp