You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Introduce a ProjectID value type in MacApp/Packages/SharedModels/Sources/SharedModels/ProjectID.swift, wrapping a canonical absolute path string. Canonicalization: URL(fileURLWithPath:).resolvingSymlinksInPath().standardizedFileURL.path. Handles edge cases: ~/, trailing slash, symlinks, relative paths.
Acceptance Criteria
ProjectID is a public struct conforming to Hashable, Codable, Sendable, Equatable, CustomStringConvertible
Public constructors: init(url: URL), init?(path: String) (nil for empty / invalid)
Canonicalization: ~/foo, /Users/me/foo/, and a symlink to /Users/me/foo all produce the same ProjectID
Unit tests cover: symlink resolution, trailing slash normalization, ~/ expansion, empty / invalid string, APFS case sensitivity
Public rawValue: String for serialization
Build passes, swiftlint lint --strict clean, all existing tests pass
Part of EPIC #193.
Description
Introduce a
ProjectIDvalue type inMacApp/Packages/SharedModels/Sources/SharedModels/ProjectID.swift, wrapping a canonical absolute path string. Canonicalization:URL(fileURLWithPath:).resolvingSymlinksInPath().standardizedFileURL.path. Handles edge cases:~/, trailing slash, symlinks, relative paths.Acceptance Criteria
ProjectIDis apublic structconforming toHashable, Codable, Sendable, Equatable, CustomStringConvertibleinit(url: URL),init?(path: String)(nil for empty / invalid)~/foo,/Users/me/foo/, and a symlink to/Users/me/fooall produce the sameProjectID~/expansion, empty / invalid string, APFS case sensitivityrawValue: Stringfor serializationswiftlint lint --strictclean, all existing tests passModule / Layer
SharedModels / Domain
Complexity
Small