ComfyMark/App/: App entry points (ComfyMarkApp,AppDelegate,AppCoordinator).ComfyMark/Coordinators/: Window/Menu/Settings flow coordination.ComfyMark/Views/: SwiftUI views and components; Metal shader atViews/Components/image.metal.ComfyMark/Models/: Rendering primitives and state (Stroke,Vertex,MetalContext).ComfyMark/Services/: App services (e.g.,ScreenshotService,ExportService).ComfyMark/Extensions/: Small utility extensions.ComfyMark/Config/:Info.plist, entitlements;Assets.xcassets/for images and colors.
- Open in Xcode:
open ComfyMark.xcodeprojthen run theComfyMarkscheme. - CLI build (Debug):
xcodebuild -scheme ComfyMark -configuration Debug -destination 'platform=macOS' build. - Tests: XCTest target not yet present. When added, run via Xcode (⌘U) or
xcodebuild ... test.
- Indentation: 4 spaces, no tabs; keep lines reasonably short (~120 cols).
- Swift naming:
UpperCamelCasefor types;lowerCamelCasefor methods/properties; files match primary type name. - Suffix patterns:
...View,...ViewModel,...Coordinator,...Service. - Imports sorted; mark sections with
// MARK:; usefinalfor non‑subclassed types. - SwiftUI: keep views small and previewable; push logic into ViewModels/Services.
- Framework: XCTest with mirror folders under
ComfyMarkTests/(e.g.,ServicesTests/ExportServiceTests.swift). - Naming:
test_<method>_<behavior>(); prefer deterministic tests. - Focus: cover core logic in Services and ViewModels; UI snapshot tests optional.
- Commits: short imperative subject (≤50 chars), optional body for rationale.
- Examples:
Add ExportService PNG support,Fix MenuBarCoordinator window focus.
- Examples:
- PRs: clear description, linked issues, before/after screenshots for UI, and test/QA steps.
- Scope: keep PRs focused; update README or comments when behavior changes.
- Review
ComfyMark/Config/ComfyMark.entitlementsbefore adding capabilities; justify changes in PRs. - Do not commit secrets; keep identifiers and signing settings consistent across schemes.