use super::RuleInfo;
use crate::model::Category;
pub(super) static RULES: &[RuleInfo] = &[
RuleInfo {
rule_id: "node.node_modules",
category: Category::Deps,
candidate: "node_modules",
restore_hint: "Run npm install, pnpm install, yarn install, or bun install",
},
RuleInfo {
rule_id: "node.next",
category: Category::Build,
candidate: ".next",
restore_hint: "Run the Next.js build or dev command",
},
RuleInfo {
rule_id: "node.turbo",
category: Category::Cache,
candidate: ".turbo",
restore_hint: "Rebuilt by Turborepo",
},
RuleInfo {
rule_id: "node.vite",
category: Category::Cache,
candidate: ".vite",
restore_hint: "Rebuilt by Vite",
},
RuleInfo {
rule_id: "node.parcel",
category: Category::Cache,
candidate: ".parcel-cache",
restore_hint: "Rebuilt by Parcel",
},
RuleInfo {
rule_id: "python.venv_dot",
category: Category::Deps,
candidate: ".venv",
restore_hint: "Recreate the Python environment",
},
RuleInfo {
rule_id: "python.venv_plain",
category: Category::Deps,
candidate: "venv",
restore_hint: "Recreate the Python environment",
},
RuleInfo {
rule_id: "python.pycache",
category: Category::Cache,
candidate: "__pycache__",
restore_hint: "Recreated by Python",
},
RuleInfo {
rule_id: "python.pytest",
category: Category::Cache,
candidate: ".pytest_cache",
restore_hint: "Recreated by pytest",
},
RuleInfo {
rule_id: "python.mypy",
category: Category::Cache,
candidate: ".mypy_cache",
restore_hint: "Recreated by mypy",
},
RuleInfo {
rule_id: "python.ruff",
category: Category::Cache,
candidate: ".ruff_cache",
restore_hint: "Recreated by ruff",
},
RuleInfo {
rule_id: "python.tox",
category: Category::Cache,
candidate: ".tox",
restore_hint: "Recreated by tox",
},
RuleInfo {
rule_id: "rust.target",
category: Category::Build,
candidate: "target",
restore_hint: "Run cargo build or cargo test",
},
RuleInfo {
rule_id: "go.vendor",
category: Category::Deps,
candidate: "vendor",
restore_hint: "Run go mod vendor",
},
RuleInfo {
rule_id: "ios.pods",
category: Category::Deps,
candidate: "Pods",
restore_hint: "Run pod install",
},
RuleInfo {
rule_id: "java.maven_target",
category: Category::Build,
candidate: "target",
restore_hint: "Run Maven build",
},
RuleInfo {
rule_id: "java.gradle_build",
category: Category::Build,
candidate: "build",
restore_hint: "Run Gradle build",
},
RuleInfo {
rule_id: "java.gradle_cache_local",
category: Category::Cache,
candidate: ".gradle",
restore_hint: "Rebuilt by Gradle",
},
RuleInfo {
rule_id: "dart.build",
category: Category::Build,
candidate: "build",
restore_hint: "Run flutter build or dart build",
},
RuleInfo {
rule_id: "dart.tool",
category: Category::Cache,
candidate: ".dart_tool",
restore_hint: "Run flutter pub get or dart pub get",
},
RuleInfo {
rule_id: "dotnet.bin",
category: Category::Build,
candidate: "bin",
restore_hint: "Run dotnet build",
},
RuleInfo {
rule_id: "dotnet.obj",
category: Category::Build,
candidate: "obj",
restore_hint: "Run dotnet build",
},
RuleInfo {
rule_id: "ruby.bundle",
category: Category::Cache,
candidate: ".bundle",
restore_hint: "Run bundle install",
},
RuleInfo {
rule_id: "ruby.vendor_bundle",
category: Category::Deps,
candidate: "vendor/bundle",
restore_hint: "Run bundle install",
},
RuleInfo {
rule_id: "generic.coverage",
category: Category::Test,
candidate: "coverage",
restore_hint: "Re-run the test suite",
},
RuleInfo {
rule_id: "node.build",
category: Category::Build,
candidate: "build",
restore_hint: "Re-run the project build",
},
RuleInfo {
rule_id: "node.dist",
category: Category::Build,
candidate: "dist",
restore_hint: "Re-run the project build",
},
RuleInfo {
rule_id: "node.out",
category: Category::Build,
candidate: "out",
restore_hint: "Re-run the project build",
},
RuleInfo {
rule_id: "xcode.derived_data",
category: Category::Build,
candidate: "DerivedData",
restore_hint: "Xcode will repopulate it on the next build",
},
RuleInfo {
rule_id: "cargo.registry_cache",
category: Category::Cache,
candidate: "cache",
restore_hint: "Cargo will redownload crates on the next build",
},
RuleInfo {
rule_id: "cargo.git_db",
category: Category::Cache,
candidate: "db",
restore_hint: "Cargo will re-clone git dependencies on the next build",
},
RuleInfo {
rule_id: "homebrew.downloads",
category: Category::Cache,
candidate: "downloads",
restore_hint: "Homebrew will redownload bottles or source archives on the next install/upgrade",
},
RuleInfo {
rule_id: "android_sdk.download_intermediates",
category: Category::Cache,
candidate: ".downloadIntermediates",
restore_hint: "Android Studio or sdkmanager will recreate SDK download intermediates",
},
RuleInfo {
rule_id: "android_sdk.legacy_build_cache",
category: Category::Cache,
candidate: "build-cache",
restore_hint: "Android Gradle Plugin will rebuild cache entries on the next build",
},
RuleInfo {
rule_id: "jetbrains.system_caches",
category: Category::Cache,
candidate: "JetBrains IDE caches",
restore_hint: "Close the IDE first; it will recreate logs and caches on the next launch",
},
RuleInfo {
rule_id: "jetbrains.logs",
category: Category::Cache,
candidate: "JetBrains IDE logs",
restore_hint: "Close the IDE first; it will recreate logs and caches on the next launch",
},
RuleInfo {
rule_id: "android_studio.system_caches",
category: Category::Cache,
candidate: "Android Studio caches",
restore_hint: "Close Android Studio first; it will recreate logs and caches on the next launch",
},
RuleInfo {
rule_id: "android_studio.logs",
category: Category::Cache,
candidate: "Android Studio logs",
restore_hint: "Close Android Studio first; it will recreate logs and caches on the next launch",
},
RuleInfo {
rule_id: "dart.pub_hosted_cache",
category: Category::Cache,
candidate: "hosted",
restore_hint: "Hosted packages will redownload on the next `dart pub get` or `flutter pub get`",
},
RuleInfo {
rule_id: "dart.pub_git_cache",
category: Category::Cache,
candidate: "git",
restore_hint: "Git dependencies will reclone on the next `dart pub get` or `flutter pub get`",
},
RuleInfo {
rule_id: "go.module_download_cache",
category: Category::Cache,
candidate: "download",
restore_hint: "Run go mod download or rebuild/test to redownload modules",
},
RuleInfo {
rule_id: "go.module_cache",
category: Category::Cache,
candidate: "mod",
restore_hint: "Run go mod download or rebuild/test to redownload modules",
},
RuleInfo {
rule_id: "go.build_cache",
category: Category::Cache,
candidate: "go-build",
restore_hint: "Go will rebuild cached objects on the next build or test",
},
RuleInfo {
rule_id: "node.npm_cacache",
category: Category::Cache,
candidate: "_cacache",
restore_hint: "npm will rebuild the cache on the next install",
},
RuleInfo {
rule_id: "node.npm_transient",
category: Category::Cache,
candidate: "_npx/_logs/_prebuilds",
restore_hint: "npm will recreate this transient cache when needed",
},
RuleInfo {
rule_id: "node.pnpm_store",
category: Category::Cache,
candidate: "store",
restore_hint: "pnpm will rebuild the store on the next install",
},
RuleInfo {
rule_id: "node.yarn_cache",
category: Category::Cache,
candidate: "Yarn",
restore_hint: "Yarn will rebuild the cache on the next install",
},
RuleInfo {
rule_id: "js.deno_cache",
category: Category::Cache,
candidate: "deno",
restore_hint: "Run `deno cache --reload`; Deno will refetch on the next run",
},
RuleInfo {
rule_id: "pip.cache",
category: Category::Cache,
candidate: "pip",
restore_hint: "pip will repopulate the cache on the next install",
},
RuleInfo {
rule_id: "ai.huggingface_hub",
category: Category::Cache,
candidate: "hub",
restore_hint: "Use `huggingface-cli delete-cache` for guided cleanup",
},
RuleInfo {
rule_id: "ai.torch_hub",
category: Category::Cache,
candidate: "hub",
restore_hint: "Recreated automatically on the next `torch.hub.load()`",
},
RuleInfo {
rule_id: "ai.vllm_compile_cache",
category: Category::Cache,
candidate: "torch_compile_cache",
restore_hint: "vLLM will rebuild compile artifacts on the next model/server start",
},
RuleInfo {
rule_id: "ai.whisper_models",
category: Category::Cache,
candidate: "whisper",
restore_hint: "Whisper will re-download the selected model on the next run",
},
RuleInfo {
rule_id: "ai.llama_cpp_cache",
category: Category::Deps,
candidate: "llama.cpp",
restore_hint: "Re-download or restore llama.cpp model files manually",
},
RuleInfo {
rule_id: "ai.ollama_models",
category: Category::Deps,
candidate: "models",
restore_hint: "Run `ollama pull <model>` per model (user data, report-only)",
},
RuleInfo {
rule_id: "ai.whisper_cpp_models",
category: Category::Deps,
candidate: "models",
restore_hint: "Run whisper.cpp's model download script for models you want back",
},
RuleInfo {
rule_id: "ai.comfyui_models",
category: Category::Deps,
candidate: "models",
restore_hint: "Restore ComfyUI models from your sources or download them again",
},
RuleInfo {
rule_id: "browser.puppeteer",
category: Category::Cache,
candidate: "puppeteer",
restore_hint: "Run `npx puppeteer browsers install chrome` to re-download Chrome for Testing",
},
RuleInfo {
rule_id: "python.uv_cache",
category: Category::Cache,
candidate: "uv",
restore_hint: "Run `uv cache clean`; uv will repopulate on the next sync",
},
RuleInfo {
rule_id: "python.poetry_cache",
category: Category::Cache,
candidate: "pypoetry",
restore_hint: "Poetry will repopulate the cache on the next install",
},
RuleInfo {
rule_id: "python.pipx_cache",
category: Category::Cache,
candidate: "pipx",
restore_hint: "pipx will repopulate the cache on the next `pipx run`",
},
RuleInfo {
rule_id: "gradle.caches",
category: Category::Cache,
candidate: "caches",
restore_hint: "Gradle will redownload dependencies on the next build",
},
RuleInfo {
rule_id: "maven.local_repo",
category: Category::Cache,
candidate: "repository",
restore_hint: "Maven will redownload dependencies on the next build",
},
RuleInfo {
rule_id: "xcode.simulators",
category: Category::Cache,
candidate: "CoreSimulator",
restore_hint: "Xcode will recreate simulators on the next iOS app run",
},
RuleInfo {
rule_id: "bun.cache",
category: Category::Cache,
candidate: "cache",
restore_hint: "bun will repopulate the cache on the next install",
},
RuleInfo {
rule_id: "pre_commit.cache",
category: Category::Cache,
candidate: "pre-commit",
restore_hint: "pre-commit will reinitialize hooks on the next run",
},
RuleInfo {
rule_id: "playwright.browsers",
category: Category::Cache,
candidate: "ms-playwright",
restore_hint: "Playwright will redownload browsers on next `npx playwright install`",
},
RuleInfo {
rule_id: "app.shipit_caches",
category: Category::Cache,
candidate: "*.ShipIt",
restore_hint: "none — these are leftover update packages from completed app updates",
},
RuleInfo {
rule_id: "chrome.cache",
category: Category::Cache,
candidate: "Chrome",
restore_hint: "Chrome will repopulate the cache on next browsing",
},
RuleInfo {
rule_id: "chrome.google_updater",
category: Category::Cache,
candidate: "GoogleUpdater",
restore_hint: "Chrome's updater will recreate it on next launch",
},
RuleInfo {
rule_id: "app.lark_cache",
category: Category::Cache,
candidate: "LarkInternational",
restore_hint: "Lark/Feishu will recreate this cache on next launch",
},
RuleInfo {
rule_id: "macos.chrome_code_sign_clone",
category: Category::Cache,
candidate: "com.google.Chrome.code_sign_clone",
restore_hint: "Chrome/macOS will recreate temporary code-sign clone data when needed",
},
RuleInfo {
rule_id: "macos.remem_dry_run_tmp",
category: Category::Cache,
candidate: "remem-dry-run-*",
restore_hint: "No restore needed; persistent remem state lives outside this dry-run temp path",
},
RuleInfo {
rule_id: "agent.tmp_worktree",
category: Category::Cache,
candidate: "remem-*, rclean-*, loom-*, *review-target*",
restore_hint: "Recreate or reclone the temporary worktree",
},
RuleInfo {
rule_id: "apple.wallpaper_aerial_videos",
category: Category::Cache,
candidate: "videos",
restore_hint: "System Settings > Wallpaper will redownload selected aerials on demand",
},
RuleInfo {
rule_id: "apple.idleassetsd",
category: Category::Cache,
candidate: "com.apple.idleassetsd",
restore_hint: "System Settings > Wallpaper will redownload selected idle assets on demand",
},
RuleInfo {
rule_id: "chrome.opt_guide_model",
category: Category::Cache,
candidate: "OptGuideOnDeviceModel",
restore_hint: "Chrome can redownload or rebuild this optimization model when needed",
},
RuleInfo {
rule_id: "app.lark_update",
category: Category::Cache,
candidate: "update",
restore_hint: "Lark/Feishu will download future updates again when needed",
},
RuleInfo {
rule_id: "macos.geod_map_tiles",
category: Category::Cache,
candidate: "MapTiles",
restore_hint: "Maps and location services will redownload map tiles on demand",
},
RuleInfo {
rule_id: "macos.mediaanalysisd_cache",
category: Category::Cache,
candidate: "com.apple.mediaanalysisd",
restore_hint: "Photos/media analysis services will rebuild this cache when needed",
},
RuleInfo {
rule_id: "macos.mediaanalysisd_tmp",
category: Category::Cache,
candidate: "MediaCache",
restore_hint: "mediaanalysisd will recreate temporary media analysis data when needed",
},
RuleInfo {
rule_id: "ruby.bundle_compact_index",
category: Category::Cache,
candidate: "compact_index",
restore_hint: "Bundler will refetch the compact index on the next install",
},
RuleInfo {
rule_id: "cloud.kube_cache",
category: Category::Cache,
candidate: "cache",
restore_hint: "kubectl will recreate the discovery cache on the next use",
},
RuleInfo {
rule_id: "cloud.gcloud_logs",
category: Category::Cache,
candidate: "logs",
restore_hint: "gcloud will recreate logs on the next run",
},
RuleInfo {
rule_id: "editor.vscode_cache",
category: Category::Cache,
candidate: "logs/Cache/CachedData/Code Cache/GPUCache",
restore_hint: "Close VS Code first; it will recreate this cache on launch",
},
RuleInfo {
rule_id: "editor.cursor_cache",
category: Category::Cache,
candidate: "logs/Cache/CachedData/Code Cache/GPUCache",
restore_hint: "Close Cursor first; it will recreate this cache on launch",
},
RuleInfo {
rule_id: "editor.vscode_obsolete_extension",
category: Category::Deps,
candidate: "<publisher>.<name>-<old-version>",
restore_hint: "Reinstall the extension from the marketplace if needed",
},
RuleInfo {
rule_id: "editor.cursor_obsolete_extension",
category: Category::Deps,
candidate: "<publisher>.<name>-<old-version>",
restore_hint: "Reinstall the extension from the marketplace if needed",
},
RuleInfo {
rule_id: "claude.old_version",
category: Category::Deps,
candidate: "<old-semver>",
restore_hint: "Claude Code can reinstall the version if it is needed again",
},
RuleInfo {
rule_id: "app.electron_cache",
category: Category::Cache,
candidate: "Cache/Code Cache/GPUCache/Dawn*Cache",
restore_hint: "Close the app first; it will recreate this cache on launch",
},
];