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
motivaton: SwiftPM clients need to reverse engineer the package identity from the url
changes:
* add PackageIdentity to WorkspaceDelegate::willFetchPackage
* add PackageIdentity to WorkspaceDelegate::fetchingPackage
* add PackageIdentity to WorkspaceDelegate::didFetchPackage
* rename WorkspaceDelegate::repositoryWillUpdate to WorkspaceDelegate::willUpdateRepository and add PackageIdentity
* rename WorkspaceDelegate::repositoryDidUpdate to WorkspaceDelegate::didUpdateRepository and add PackageIdentity
* add PackageIdentity to WorkspaceDelegate::willCreateWorkingCopy
* add PackageIdentity to WorkspaceDelegate::didCreateWorkingCopy
* add PackageIdentity to WorkspaceDelegate::willCheckOut
* add PackageIdentity to WorkspaceDelegate::didCheckOut
* add PackageIdentity to WorkspaceDelegate::removing
* remove redundant (not in use) Diagnostics argument from WorkspaceDelegate::didCreateWorkingCopy
* remove redundant (not in use) Diagnostics argument from WorkspaceDelegate::didCheckOut
* update call sites and test
@@ -203,12 +208,14 @@ public class RepositoryManager {
203
208
204
209
/// Fetches the repository into the cache. If no `cachePath` is set or an error occurred fall back to fetching the repository without populating the cache.
205
210
/// - Parameters:
211
+
/// - package: The package identity of the repository to fetch.
206
212
/// - handle: The specifier of the repository to fetch.
207
213
/// - repositoryPath: The path where the repository should be fetched to.
208
214
/// - observabilityScope: The observability scope
209
215
/// - delegateQueue: Dispatch queue for delegate events
210
216
@discardableResult
211
-
func fetchAndPopulateCache(
217
+
privatefunc fetchAndPopulateCache(
218
+
package:PackageIdentity,
212
219
handle:RepositoryHandle,
213
220
repositoryPath:AbsolutePath,
214
221
observabilityScope:ObservabilityScope,
@@ -223,6 +230,7 @@ public class RepositoryManager {
223
230
iflet total = progress.totalSteps {
224
231
delegateQueue.async{
225
232
self.delegate?.fetching(
233
+
package:package,
226
234
repository: handle.repository,
227
235
objectsFetched: progress.step,
228
236
totalObjectsToFetch: total
@@ -273,8 +281,6 @@ public class RepositoryManager {
273
281
tryself.provider.fetch(repository: handle.repository, to: repositoryPath, progressHandler:updateFetchProgress(progress:))
0 commit comments