Skip to content

Commit ea98260

Browse files
committed
Move now to Workspace
1 parent d8065c3 commit ea98260

1 file changed

Lines changed: 10 additions & 1 deletion

File tree

Tool/Sources/Workspace/Workspace.swift

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,13 @@
1-
import Environment
21
import Foundation
32
import Preferences
43
import SuggestionModel
54
import UserDefaultsObserver
65
import XcodeInspector
76

7+
enum Environment {
8+
static var now = { Date() }
9+
}
10+
811
public protocol WorkspacePropertyKey {
912
associatedtype Value
1013
static func createDefaultValue() -> Value
@@ -58,6 +61,12 @@ public final class Workspace {
5861
}
5962
}
6063

64+
public struct CantFindWorkspaceError: Error, LocalizedError {
65+
public var errorDescription: String? {
66+
"Can't find workspace."
67+
}
68+
}
69+
6170
private var additionalProperties = WorkspacePropertyValues()
6271
public internal(set) var plugins = [ObjectIdentifier: WorkspacePlugin]()
6372
public let workspaceURL: URL

0 commit comments

Comments
 (0)