Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Three-way diffing Synchronizer #1707

Merged
merged 18 commits into from
Jul 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -34,18 +34,4 @@ protected void Init(string baseModName, string fileList)
_installation = _datamodel.BaseLoadout.InstallationInstance;
_diskStateRegistry = _serviceProvider.GetRequiredService<IDiskStateRegistry>();
}

protected void InitForIngest()
{
// We apply the files of a new loadout (without updating the loadout itself)
// This way we have loose files to ingest.
Task.Run(async () =>
{
// Do an apply, but without updating the loadout revision.
var flattenedLoadout = await _defaultSynchronizer.LoadoutToFlattenedLoadout(_datamodel.BaseLoadout);
var fileTree = await _defaultSynchronizer.FlattenedLoadoutToFileTree(flattenedLoadout, _datamodel.BaseLoadout);
var prevState = _datamodel.DiskStateRegistry.GetState(_installation)!;
await _defaultSynchronizer.FileTreeToDiskImpl(fileTree, _datamodel.BaseLoadout, flattenedLoadout, prevState, _installation,false);
}).Wait();
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ public Task BackupFiles(IEnumerable<ArchivedFileEntry> backups, CancellationToke
return Task.CompletedTask;
}

public Task ExtractFiles((Hash Hash, AbsolutePath Dest)[] files, CancellationToken token = default)
public Task ExtractFiles(IEnumerable<(Hash Hash, AbsolutePath Dest)> files, CancellationToken token = default)
{
return Task.CompletedTask;
}
Expand Down

This file was deleted.

This file was deleted.

Loading
Loading