Skip to content

Commit 7a0f81a

Browse files
authored
Use URL.homeDirectory instead of FileManager.homeDirectoryForCurrentUser. (#411)
`FileManager.homeDirectoryForCurrentUser` is only available for macOS on Apple platforms, which breaks building SwiftBuild for iOS.
1 parent b91412e commit 7a0f81a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Sources/SWBCore/SwiftSDK.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ public struct SwiftSDK: Sendable {
7979
create: false
8080
).appendingPathComponent("org.swift.swiftpm")
8181
} else {
82-
spmURL = FileManager.default.homeDirectoryForCurrentUser.appendingPathComponent(".swiftpm")
82+
spmURL = URL.homeDirectory.appendingPathComponent(".swiftpm")
8383
}
8484
return try spmURL.appendingPathComponent("swift-sdks").filePath
8585
}

0 commit comments

Comments
 (0)