Guidance for coding agents working in this repository.
- Product:
XcodeCleaner - Language/stack: Swift + SwiftUI (macOS 14+), SwiftPM + Xcode project for GUI packaging
- Deliverables:
XcodeCleanerApp(GUI)xcodecleaner-cli(CLI)- Distribution model: source-first (clone + local build). Signing/notarization is optional future work, not a current gate.
- Work in small, reviewable chunks with incremental value.
- Current sequencing:
- Keep the GUI codebase organized and workflow-oriented.
- Update docs after structural changes.
- Do packaging/icon/release work after the codebase and docs are aligned.
- Keep CLI and GUI parity for shared capabilities when technically applicable.
- Do not commit or push unless the user explicitly asks.
- For chunked work:
- Implement chunk.
- Run tests.
- Provide a concise review checklist.
- Wait for user approval before committing.
- If user asks to commit after each chunk, follow that exactly.
- Do not prepend Conventional Commit prefixes (for example,
fix(app):) unless the user explicitly asks for that format. - Use a concise plain-language subject line by default.
- Preserve cleanup guardrails:
- Protect active/running Xcode installs.
- Protect booted/running simulator devices.
- Move to Trash first; direct-delete fallback only when explicitly enabled.
- Avoid destructive commands unless explicitly requested.
- Do not remove user changes you did not create.
- Use local module cache env vars for SwiftPM commands:
CLANG_MODULE_CACHE_PATH=$PWD/.build/clang-module-cache \
SWIFTPM_MODULECACHE_OVERRIDE=$PWD/.build/swift-module-cache \
swift test --disable-sandbox- Run CLI:
CLANG_MODULE_CACHE_PATH=$PWD/.build/clang-module-cache \
SWIFTPM_MODULECACHE_OVERRIDE=$PWD/.build/swift-module-cache \
swift run --disable-sandbox xcodecleaner-cli- Run GUI:
CLANG_MODULE_CACHE_PATH=$PWD/.build/clang-module-cache \
SWIFTPM_MODULECACHE_OVERRIDE=$PWD/.build/swift-module-cache \
swift run --disable-sandbox XcodeCleanerApp- Build the bundled GUI app:
Scripts/build-xcodecleaner-app.shPackage.swift: package/products/targets.XcodeCleaner.xcodeproj: macOS app project for the bundled GUI target.Xcode/XcodeCleanerApp/*: bundle metadata andAssets.xcassetsfor the GUI app.Scripts/build-xcodecleaner-app.sh: repeatablexcodebuildwrapper forXcodeCleaner.app.Sources/XcodeInventoryCore/*: scanner, models, planning, execution, automation core.Sources/XcodeCleanerCLI/*: CLI modes, options, output/progress behavior.Sources/XcodeCleanerApp/XcodeCleanerApp.swift: app entry point.Sources/XcodeCleanerApp/App/*: app lifecycle helpers.Sources/XcodeCleanerApp/ViewModels/*: GUI state coordination.Sources/XcodeCleanerApp/Views/Sections/*: workflow-specific section views.Sources/XcodeCleanerApp/Views/Components/*: shared app UI panels.Sources/XcodeCleanerApp/State/*: app-only form and selection state.Sources/XcodeCleanerApp/Support/*: app-only presentation helpers and section metadata.docs/DEVELOPMENT_TODO.md: current milestone ordering and release-adjacent follow-up work.docs/REPORT_SCHEMA.md: report/export schema details.
- Update
README.md,AGENTS.md, anddocs/DEVELOPMENT_TODO.mdwhen structure or milestone ordering changes. - Keep release/readme docs aligned with implemented behavior (especially GUI/CLI parity and distribution assumptions).