{"id":13437098,"url":"https://github.com/darakian/ddh","last_synced_at":"2025-05-16T09:03:39.687Z","repository":{"id":40680437,"uuid":"116137510","full_name":"darakian/ddh","owner":"darakian","description":"A fast duplicate file finder","archived":false,"fork":false,"pushed_at":"2022-11-13T19:49:39.000Z","size":243,"stargazers_count":461,"open_issues_count":1,"forks_count":19,"subscribers_count":9,"default_branch":"master","last_synced_at":"2025-04-09T04:02:56.178Z","etag":null,"topics":["cli","rust"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/darakian.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-01-03T13:03:17.000Z","updated_at":"2025-03-30T08:35:26.000Z","dependencies_parsed_at":"2023-01-21T08:45:11.696Z","dependency_job_id":null,"html_url":"https://github.com/darakian/ddh","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/darakian%2Fddh","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/darakian%2Fddh/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/darakian%2Fddh/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/darakian%2Fddh/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/darakian","download_url":"https://codeload.github.com/darakian/ddh/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254501554,"owners_count":22081528,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cli","rust"],"created_at":"2024-07-31T03:00:54.304Z","updated_at":"2025-05-16T09:03:39.601Z","avatar_url":"https://github.com/darakian.png","language":"Rust","readme":"# The **D**irectory **D**ifferential **h**Tool\nDDH traverses input directories and their subdirectories. It also hashes files as needed and reports findings.\n\nThe H in \"hTool\" is silent. The H in its abbreviation, \"DDH,\" is not.\n\nThis tool is called DDH for two very good reasons.\n* DDT is a dangerous pesticide\n* I mistyped when I created the project\n\n## Usage\nDDH is usable both as a library and as a stand alone CLI tool and aims to be simple to use in both cases.\n\n## Library example\n```rust\nlet (files, errors): (Vec\u003cFileinfo\u003e, Vec\u003c(_, _)\u003e) = ddh::deduplicate_dirs(dirs);\nlet (shared, unique): (Vec\u003c\u0026Fileinfo\u003e, Vec\u003c\u0026Fileinfo\u003e) = files\n                    .par_iter()\n                    .partition(|\u0026x| x.get_paths().len()\u003e1);\nprocess_full_output(\u0026shared, \u0026unique, \u0026files, \u0026errors, \u0026arguments);\n```\n\n## CLI Install\n* Install [Rust](https://www.rust-lang.org/en-US/install.html)\n* `cargo install --git https://github.com/darakian/ddh ddh`\n* The DDH binary will be installed into `$CARGO_HOME/.bin/ddh`, which usually is `$HOME/.cargo/bin/ddh`. This should be in your `PATH` already if you're using rustup.\n\n## CLI Features\nDDH supports both a `standard` output for human comprehension and a parsable `json` output for custom tools such as [ddh-move](https://github.com/JayWalker512/ddh-move).\n\n## CLI Example\n```\nDirectory Difference hTool\nJon Moroney jmoroney@hawaii.edu\nCompare and contrast directories.\n\nExample invocation: ddh -v duplicates -d /home/jon/downloads /home/jon/documents\nExample pipe: ddh -o no -v all -f json -d ~/Downloads/ | someJsonParser.bin\n\nUsage: ddh [OPTIONS]\n\nOptions:\n  -m, --minimum [\u003cMIN_SIZE\u003e]\n          Minimum file size in bytes to consider [default: 0]\n  -b, --blocksize [\u003cBLOCKSIZE\u003e]\n          Set the display blocksize to Bytes, Kilobytes, Megabytes or Gigabytes [default: K] [possible values: B, K, M, G]\n  -v, --verbosity [\u003cVERBOSITY\u003e]\n          Set verbosity for printed output [default: quiet] [possible values: quiet, duplicates, all]\n  -o, --output [\u003cOUTPUT\u003e]\n          Set file to save all output. Use 'no' for no file output [default: Results.txt]\n  -f, --format [\u003cFMT\u003e]\n          Set output format [default: standard] [possible values: standard, json]\n  -i, --ignore \u003cIGNORE_DIRS\u003e\n          Directories to ignore (comma separated list)\n  -d, --directories \u003cDIRECTORIES\u003e...\n          Directories to parse\n  -h, --help\n          Print help information (use `--help` for more detail)\n  -V, --version\n          Print version information\n```\n## How Does DDH Work?\nDDH works by hashing files to determine their uniqueness and, as such, depends heavily on disk speeds for performance. The algorithmic choices in use are discussed [here](https://darakian.github.io/2018/04/02/how-many-bytes-does-it-take.html).\n","funding_links":[],"categories":["Applications","Rust","应用程序 Applications","应用","应用 Applications","cli"],"sub_categories":["System tools","系统工具 System tools","系统工具"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdarakian%2Fddh","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdarakian%2Fddh","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdarakian%2Fddh/lists"}