dupehunt
English | 中文
按内容哈希查找重复文件,零依赖的命令行工具。
安装
pip install dupehunt
用法
$ dupehunt ~/Downloads
3 group(s), 9 file(s), 412.6 MB reclaimable
[1] 180.0 MB x 3 (360.0 MB wasted)
/home/me/Downloads/ubuntu.iso
/home/me/Downloads/ubuntu (1).iso
/home/me/Downloads/backup/ubuntu.iso
$ dupehunt ~/data --json > dupes.json
$ dupehunt ~/data --delete -m 1M # 演练
$ dupehunt ~/data --delete --yes -m 1M # 真删
说明
三遍扫描由便宜到贵:先按大小分组、再哈希前 8 KiB、最后才对仍然碰撞的候选做全文件哈希,因此全盘扫描也不慢。符号链接不跟随,同一 inode 的硬链接只计一次。--delete 不带 --yes 永远是演练,不删任何东西。
许可证
MIT
English
Fast, dependency-free duplicate file finder with a friendly CLI.
Install
pip install dupehunt
Usage
$ dupehunt ~/Downloads
3 group(s), 9 file(s), 412.6 MB reclaimable
[1] 180.0 MB x 3 (360.0 MB wasted)
/home/me/Downloads/ubuntu.iso
/home/me/Downloads/ubuntu (1).iso
/home/me/Downloads/backup/ubuntu.iso
$ dupehunt ~/data --json > dupes.json
$ dupehunt ~/data --delete -m 1M # 演练
$ dupehunt ~/data --delete --yes -m 1M # 真删
Notes
Three passes, cheapest first: group by size, hash the first 8 KiB, then hash whole files only for surviving candidates. Symlinks are not followed and hard links to the same inode count once. --delete without --yes is always a dry run.
License
MIT
Metadata
Release files for dupehunt 0.0.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| dupehunt-0.0.3.tar.gz | 7.0 kB | Without provenance | Details for dupehunt-0.0.3.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| dupehunt-0.0.3-py3-none-any.whl | Python 3 | none | any | Details for dupehunt-0.0.3-py3-none-any.whl |
Total release size: 14.9 kB
Release files / dupehunt-0.0.3.tar.gz
| Download URL | dupehunt-0.0.3.tar.gz |
|---|---|
| Size | 7.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
9c0bac870d4e54d565b8f2deb918a03cb5a12eaba4a2e51e4b22182812934c52
|
|
BLAKE2b-256 checksum How to use checksums |
d2f1a4743e963fccff8b6f42f86aa6b26d27c549a019d352af17dc357e498eda
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.10.11
|
Release files / dupehunt-0.0.3-py3-none-any.whl
| Download URL | dupehunt-0.0.3-py3-none-any.whl |
|---|---|
| Size | 7.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
3859c1bcf720bcf58b5f5058180c3b6579c994d30c04c0f64c64c78b16dc8858
|
|
BLAKE2b-256 checksum How to use checksums |
fbee7eea7f5bdd8b5e18aa2058741adf18a0c82cbca8402001add19267bdac18
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.10.11
|
Security for dupehunt 0.0.3
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.
No provenance found
None of the files in this release were uploaded with provenance metadata.
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.