{"id":51668828,"url":"https://github.com/kingchenc/diskghost","last_synced_at":"2026-07-14T22:33:03.510Z","repository":{"id":368757190,"uuid":"1286677016","full_name":"kingchenc/diskghost","owner":"kingchenc","description":"Fast disk usage \u0026 duplicate finder, written in Rust (CLI + JSON for agents; modern GUI coming).","archived":false,"fork":false,"pushed_at":"2026-07-02T04:34:02.000Z","size":460,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-07-02T05:05:32.037Z","etag":null,"topics":["blake3","cli","cross-platform","deduplication","disk-analyzer","disk-space","disk-usage","du","duplicate-files","duplicate-finder","file-management","filesystem","gui","ncdu","performance","rayon","rust","storage","tauri","windows"],"latest_commit_sha":null,"homepage":null,"language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/kingchenc.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-07-02T02:21:48.000Z","updated_at":"2026-07-02T04:30:56.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/kingchenc/diskghost","commit_stats":null,"previous_names":["kingchenc/diskghost"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/kingchenc/diskghost","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kingchenc%2Fdiskghost","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kingchenc%2Fdiskghost/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kingchenc%2Fdiskghost/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kingchenc%2Fdiskghost/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/kingchenc","download_url":"https://codeload.github.com/kingchenc/diskghost/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kingchenc%2Fdiskghost/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":35482260,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-07-14T02:00:06.603Z","response_time":114,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["blake3","cli","cross-platform","deduplication","disk-analyzer","disk-space","disk-usage","du","duplicate-files","duplicate-finder","file-management","filesystem","gui","ncdu","performance","rayon","rust","storage","tauri","windows"],"created_at":"2026-07-14T22:33:03.415Z","updated_at":"2026-07-14T22:33:03.502Z","avatar_url":"https://github.com/kingchenc.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003ch1 align=\"center\"\u003eDiskghost 👻\u003c/h1\u003e\n\n\u003cp align=\"center\"\u003e\u003cb\u003eFast disk-usage \u0026amp; duplicate finder, written in Rust.\u003c/b\u003e\u003cbr\u003e\nFind where your space went, hunt down byte-identical duplicates, and reclaim the space — from a CLI, a JSON API for agents, or a modern desktop app.\u003c/p\u003e\n\n---\n\n## Features\n\n- **Parallel scan** (`jwalk` + `rayon`) — total size, biggest sub-folders and\n  biggest files, files-directly-in-root, and a count of unreadable/skipped\n  entries. Also reports the drive's **free / total space** and how long the\n  scan took.\n- **Correct duplicate detection** — group by size → **collapse hard links**\n  (same physical file, so `wasted` is real) → **first-block pre-hash** → full\n  **BLAKE3** hash, all in parallel.\n- **Reclaim duplicates** — delete, send to the **OS trash/recycle bin**, or\n  replace a copy with a **hard link**. Dry-run by default.\n- **Delete a file or folder** — `diskghost rm \u003cpath\u003e`, permanently or to the OS\n  trash. Parallel unlink for speed, never follows symlinks (can't escape the\n  target), refuses a drive root, dry-run by default, reports how long it took.\n- **Scan options** — exclude globs (`node_modules`, `*.tmp`), max depth,\n  follow-symlinks.\n- **Live progress + cancel** — long scans report files/bytes and can be stopped.\n- **Three faces, one Rust core**:\n  - a **CLI** with `--json` output for scripts and agents (headless);\n  - a **modern desktop GUI** (Tauri) with a treemap, folder picker, drag \u0026amp; drop\n    and one-click reclaim.\n\n## Install\n\n```bash\n# Install the `diskghost` command globally, straight from GitHub (no crates.io):\ncargo install --git https://github.com/kingchenc/diskghost diskghost-cli\n\n# ...or from a local checkout:\ncargo install --path crates/diskghost-cli\n\n# ...or grab a prebuilt binary from the GitHub Releases page (Linux/macOS/Windows,\n# each with a SHA256 checksum + build-provenance attestation) — no toolchain needed.\n```\n\n## CLI usage\n\n```bash\n# Biggest sub-folders and files\ndiskghost scan \"C:\\Users\\me\\Desktop\" --top 20\n\n# Scan options\ndiskghost scan . --exclude node_modules --exclude \"*.tmp\" --max-depth 3 --follow-symlinks\n\n# Duplicates (ignore anything under 5 MB)\ndiskghost dupes \"D:\\Media\" --min-mb 5\n\n# Reclaim: dry-run first (default), then apply\ndiskghost dupes \"D:\\Media\" --min-mb 5 --reclaim trash          # shows what would happen\ndiskghost dupes \"D:\\Media\" --min-mb 5 --reclaim trash --apply  # actually acts\n#   --reclaim delete | trash | hardlink   (one file per group is always kept)\n\n# Delete a file or folder — dry-run first (default), then apply\ndiskghost rm \"D:\\old_project\\target\"            # shows how many files/dirs/bytes would go\ndiskghost rm \"D:\\old_project\\target\" --apply    # permanently delete (files unlinked in parallel)\ndiskghost rm \"D:\\old_project\\target\" --trash --apply   # send to the OS recycle bin instead\n#   never follows symlinks (can't escape the target); refuses a drive root\n```\n\n### Headless / agent mode\n\nAdd `--json` to any command for machine-readable output:\n\n```bash\ndiskghost scan . --json          # total_size, children, top_files, root_files, skipped …\ndiskghost dupes . --min-mb 10 --json   # duplicate groups with reclaimable bytes\n```\n\nPerfect for wiring into an automation/agent that decides what to clean.\n\n## Desktop app (GUI)\n\nA modern Tauri UI lives in `gui/` — **Browse** or drag a folder onto the window,\nhit **Scan size** for a treemap + biggest folders/files (click a folder to drill\nin), or **Find duplicates** to sort/filter groups and reclaim their space with one\nclick. Scans show live progress and can be cancelled. From `gui/src-tauri`:\n\n```bash\ncargo tauri dev      # run the app\ncargo tauri build    # bundle an installer\n```\n\n## Why it's fast — and correct\n\n- Parallel directory walk across all cores; a **single pass** counts files *and*\n  directories.\n- Duplicate detection never hashes more than it must: size buckets first, hard\n  links collapsed, a cheap first-block pre-hash, then BLAKE3 — streamed, so large\n  files never load into RAM.\n- Hard links are not counted as duplicates, so the \"reclaimable\" number is the\n  space you actually get back.\n\n## Layout\n\n```\nDiskghost/\n├── crates/\n│   ├── diskghost-core/   the engine: scan + duplicate detection + reclaim (a library)\n│   └── diskghost-cli/    the `diskghost` command\n└── gui/                  Tauri desktop app (modern dark UI)\n```\n\n## Roadmap\n\n- [x] Core: parallel scan, folder/file sizes, hard-link-aware duplicate detection\n- [x] CLI with human + JSON output, scan options, reclaim (delete/trash/hardlink)\n- [x] Live progress + cancellation\n- [x] Modern GUI: treemap, folder picker, drag \u0026amp; drop, one-click reclaim\n- [x] Delete files/folders (CLI `rm` + GUI) — permanent or to the OS trash, parallel unlink\n- [x] Drive free/total space + scan \u0026amp; delete timings (CLI + GUI)\n- [x] CI (fmt/clippy/test/bench on 3 OS) + signed release binaries + GUI installers\n- [ ] Interactive treemap drill-up / breadcrumbs\n- [ ] Scheduled scans \u0026amp; \"what grew since last time\"\n\n## Development\n\n```bash\ncargo test --workspace                                   # unit + integration tests\ncargo clippy --workspace --all-targets -- -D warnings    # lints (CI gate)\ncargo bench -p diskghost-core                             # criterion benchmarks\n```\n\n## License\n\nMIT — see [LICENSE](LICENSE).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkingchenc%2Fdiskghost","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkingchenc%2Fdiskghost","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkingchenc%2Fdiskghost/lists"}