Skip to content
Merged
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
26 changes: 18 additions & 8 deletions StabilityMatrix.Core/Models/Packages/FluxGym.cs
Original file line number Diff line number Diff line change
Expand Up @@ -85,14 +85,24 @@ public override async Task InstallPackage(
CancellationToken cancellationToken = default
)
{
progress?.Report(new ProgressReport(-1f, "Cloning sd-scripts", isIndeterminate: true));
await prerequisiteHelper
.RunGit(
["clone", "-b", "sd3", "https://github.com/kohya-ss/sd-scripts"],
onConsoleOutput,
installLocation
)
.ConfigureAwait(false);
progress?.Report(new ProgressReport(-1f, "Cloning / updating sd-scripts", isIndeterminate: true));
// check if sd-scripts is already installed - if so: pull, else: clone
if (Directory.Exists(Path.Combine(installLocation, "sd-scripts")))
{
await prerequisiteHelper
.RunGit(["pull"], onConsoleOutput, Path.Combine(installLocation, "sd-scripts"))
.ConfigureAwait(false);
}
else
{
await prerequisiteHelper
.RunGit(
["clone", "-b", "sd3", "https://github.com/kohya-ss/sd-scripts"],
onConsoleOutput,
installLocation
)
.ConfigureAwait(false);
}

progress?.Report(new ProgressReport(-1f, "Setting up venv", isIndeterminate: true));
await using var venvRunner = await SetupVenvPure(installLocation).ConfigureAwait(false);
Expand Down
Loading