Browse Source

Move common classes to Core assembly

pull/55/head
Ionite 1 year ago
parent
commit
85e375123e
No known key found for this signature in database
  1. 7
      StabilityMatrix.Core/StabilityMatrix.Core/Converters/Json/DefaultUnknownEnumConverter.cs
  2. 5
      StabilityMatrix.Core/StabilityMatrix.Core/Converters/Json/LaunchOptionValueJsonConverter.cs
  3. 4
      StabilityMatrix.Core/StabilityMatrix.Core/Extensions/EnumAttributes.cs
  4. 4
      StabilityMatrix.Core/StabilityMatrix.Core/Extensions/EnumConversion.cs
  5. 5
      StabilityMatrix.Core/StabilityMatrix.Core/Extensions/EnumerableExtensions.cs
  6. 7
      StabilityMatrix.Core/StabilityMatrix.Core/Extensions/LiteDBExtensions.cs
  7. 8
      StabilityMatrix.Core/StabilityMatrix.Core/Helper/Cache/GithubApiCache.cs
  8. 7
      StabilityMatrix.Core/StabilityMatrix.Core/Helper/Cache/IGithubApiCache.cs
  9. 5
      StabilityMatrix.Core/StabilityMatrix.Core/Helper/Cache/LRUCache.cs
  10. 5
      StabilityMatrix.Core/StabilityMatrix.Core/Helper/Expressions.cs
  11. 7
      StabilityMatrix.Core/StabilityMatrix.Core/Helper/FileHash.cs
  12. 9
      StabilityMatrix.Core/StabilityMatrix.Core/Helper/FileTransfers.cs
  13. 27
      StabilityMatrix.Core/StabilityMatrix.Core/Helper/HardwareHelper.cs
  14. 6
      StabilityMatrix.Core/StabilityMatrix.Core/Helper/MinimumDelay.cs
  15. 5
      StabilityMatrix.Core/StabilityMatrix.Core/Helper/ObjectHash.cs
  16. 9
      StabilityMatrix.Core/StabilityMatrix.Core/Helper/ProcessRunner.cs
  17. 7
      StabilityMatrix.Core/StabilityMatrix.Core/Helper/ProcessTracker.cs
  18. 22
      StabilityMatrix.Core/StabilityMatrix.Core/Helper/Size.cs
  19. 4
      StabilityMatrix.Core/StabilityMatrix.Core/Helper/SystemInfo.cs
  20. 6
      StabilityMatrix.Core/StabilityMatrix.Core/Helper/Utilities.cs
  21. 2
      StabilityMatrix.Core/StabilityMatrix.Core/Models/Configs/DebugOptions.cs
  22. 6
      StabilityMatrix.Core/StabilityMatrix.Core/Models/FileInterfaces/DirectoryPath.cs
  23. 5
      StabilityMatrix.Core/StabilityMatrix.Core/Models/FileInterfaces/FilePath.cs
  24. 5
      StabilityMatrix.Core/StabilityMatrix.Core/Models/FileInterfaces/FileSystemPath.cs
  25. 4
      StabilityMatrix.Core/StabilityMatrix.Core/Models/FileInterfaces/IPathObject.cs
  26. 2
      StabilityMatrix.Core/StabilityMatrix.Core/Models/FileSizeType.cs
  27. 5
      StabilityMatrix.Core/StabilityMatrix.Core/Models/GlobalConfig.cs
  28. 12
      StabilityMatrix.Core/StabilityMatrix.Core/Models/InstalledPackage.cs
  29. 9
      StabilityMatrix.Core/StabilityMatrix.Core/Models/LaunchOption.cs
  30. 2
      StabilityMatrix.Core/StabilityMatrix.Core/Models/LaunchOptionCard.cs
  31. 5
      StabilityMatrix.Core/StabilityMatrix.Core/Models/LaunchOptionDefinition.cs
  32. 2
      StabilityMatrix.Core/StabilityMatrix.Core/Models/LaunchOptionType.cs
  33. 4
      StabilityMatrix.Core/StabilityMatrix.Core/Models/LicenseInfo.cs
  34. 2
      StabilityMatrix.Core/StabilityMatrix.Core/Models/LoadState.cs
  35. 2
      StabilityMatrix.Core/StabilityMatrix.Core/Models/PackageVersion.cs
  36. 5
      StabilityMatrix.Core/StabilityMatrix.Core/Models/SharedFolderType.cs
  37. 5
      StabilityMatrix.Core/StabilityMatrix.Core/Models/TaskResult.cs
  38. 9
      StabilityMatrix.Core/StabilityMatrix.Core/Python/ArgParser.cs
  39. 7
      StabilityMatrix.Core/StabilityMatrix.Core/Python/IPyRunner.cs
  40. 7
      StabilityMatrix.Core/StabilityMatrix.Core/Python/Interop/PyIOStream.cs
  41. 12
      StabilityMatrix.Core/StabilityMatrix.Core/Python/PyRunner.cs
  42. 13
      StabilityMatrix.Core/StabilityMatrix.Core/Python/PyVenvRunner.cs
  43. 2
      StabilityMatrix.Core/StabilityMatrix.Core/ReparsePoints/DeviceIoControlCode.cs
  44. 6
      StabilityMatrix.Core/StabilityMatrix.Core/ReparsePoints/Junction.cs
  45. 2
      StabilityMatrix.Core/StabilityMatrix.Core/ReparsePoints/ReparseDataBuffer.cs
  46. 2
      StabilityMatrix.Core/StabilityMatrix.Core/ReparsePoints/Win32CreationDisposition.cs
  47. 14
      StabilityMatrix.Core/StabilityMatrix.Core/ReparsePoints/Win32ErrorCode.cs
  48. 4
      StabilityMatrix.Core/StabilityMatrix.Core/ReparsePoints/Win32FileAccess.cs
  49. 5
      StabilityMatrix.Core/StabilityMatrix.Core/ReparsePoints/Win32FileAttribute.cs
  50. 4
      StabilityMatrix.Core/StabilityMatrix.Core/ReparsePoints/Win32FileShare.cs
  51. 22
      StabilityMatrix.Core/StabilityMatrix.Core/StabilityMatrix.Core.csproj
  52. 3
      StabilityMatrix.Tests/Models/InstalledPackageTests.cs
  53. 3
      StabilityMatrix.Tests/Models/SharedFoldersTests.cs
  54. 2
      StabilityMatrix.Tests/Python/PyRunnerTests.cs
  55. 2
      StabilityMatrix.Tests/ReparsePoints/JunctionTests.cs
  56. 6
      StabilityMatrix/App.xaml.cs
  57. 4
      StabilityMatrix/Database/LiteDbContext.cs
  58. 1
      StabilityMatrix/Helper/ArchiveHelper.cs
  59. 1
      StabilityMatrix/Helper/DialogFactory.cs
  60. 1
      StabilityMatrix/Helper/IDialogFactory.cs
  61. 1
      StabilityMatrix/Helper/ISettingsManager.cs
  62. 1
      StabilityMatrix/Helper/ISnackbarService.cs
  63. 3
      StabilityMatrix/Helper/PrerequisiteHelper.cs
  64. 4
      StabilityMatrix/Helper/SettingsManager.cs
  65. 1
      StabilityMatrix/Helper/SnackbarService.cs
  66. 4
      StabilityMatrix/InstallerWindow.xaml
  67. 2
      StabilityMatrix/LaunchOptionsDialog.xaml
  68. 1
      StabilityMatrix/LaunchOptionsDialog.xaml.cs
  69. 6
      StabilityMatrix/LaunchPage.xaml
  70. 1
      StabilityMatrix/Models/Api/CivitModel.cs
  71. 5
      StabilityMatrix/Models/Api/CivitModelType.cs
  72. 3
      StabilityMatrix/Models/CheckpointFile.cs
  73. 6
      StabilityMatrix/Models/CheckpointFolder.cs
  74. 3
      StabilityMatrix/Models/GlobalUserSecrets.cs
  75. 2
      StabilityMatrix/Models/ISharedFolders.cs
  76. 4
      StabilityMatrix/Models/Packages/A3WebUI.cs
  77. 5
      StabilityMatrix/Models/Packages/BaseGitPackage.cs
  78. 2
      StabilityMatrix/Models/Packages/BasePackage.cs
  79. 4
      StabilityMatrix/Models/Packages/ComfyUI.cs
  80. 3
      StabilityMatrix/Models/Packages/DankDiffusion.cs
  81. 6
      StabilityMatrix/Models/Packages/VladAutomatic.cs
  82. 1
      StabilityMatrix/Models/Settings/Settings.cs
  83. 7
      StabilityMatrix/Models/SharedFolders.cs
  84. 2
      StabilityMatrix/PackageManagerPage.xaml
  85. 2
      StabilityMatrix/Updater/UpdateChannel.cs
  86. 4
      StabilityMatrix/Updater/UpdateHelper.cs
  87. 6
      StabilityMatrix/ViewModels/CheckpointBrowserCardViewModel.cs
  88. 4
      StabilityMatrix/ViewModels/CheckpointBrowserViewModel.cs
  89. 5
      StabilityMatrix/ViewModels/DataDirectoryMigrationViewModel.cs
  90. 1
      StabilityMatrix/ViewModels/FirstLaunchSetupViewModel.cs
  91. 5
      StabilityMatrix/ViewModels/InstallerViewModel.cs
  92. 3
      StabilityMatrix/ViewModels/LaunchOptionsDialogViewModel.cs
  93. 4
      StabilityMatrix/ViewModels/LaunchViewModel.cs
  94. 3
      StabilityMatrix/ViewModels/MainWindowViewModel.cs
  95. 3
      StabilityMatrix/ViewModels/OneClickInstallViewModel.cs
  96. 1
      StabilityMatrix/ViewModels/PackageManagerViewModel.cs
  97. 1
      StabilityMatrix/ViewModels/SelectInstallLocationsViewModel.cs
  98. 4
      StabilityMatrix/ViewModels/SettingsViewModel.cs
  99. 3
      StabilityMatrix/ViewModels/TextToImageViewModel.cs
  100. 1
      StabilityMatrix/ViewModels/UpdateWindowViewModel.cs

7
StabilityMatrix/Converters/Json/DefaultUnknownEnumConverter.cs → StabilityMatrix.Core/StabilityMatrix.Core/Converters/Json/DefaultUnknownEnumConverter.cs

@ -1,9 +1,8 @@
using System;
using System.Text.Json;
using System.Text.Json;
using System.Text.Json.Serialization;
using StabilityMatrix.Extensions;
using StabilityMatrix.Core.Extensions;
namespace StabilityMatrix.Converters.Json;
namespace StabilityMatrix.Core.Converters.Json;
public class DefaultUnknownEnumConverter<T> : JsonConverter<T> where T : Enum
{

5
StabilityMatrix/Converters/Json/LaunchOptionValueJsonConverter.cs → StabilityMatrix.Core/StabilityMatrix.Core/Converters/Json/LaunchOptionValueJsonConverter.cs

@ -1,8 +1,7 @@
using System;
using System.Text.Json;
using System.Text.Json;
using System.Text.Json.Serialization;
namespace StabilityMatrix.Converters.Json;
namespace StabilityMatrix.Core.Converters.Json;
public class LaunchOptionValueJsonConverter : JsonConverter<object?>
{

4
StabilityMatrix/Extensions/EnumAttributes.cs → StabilityMatrix.Core/StabilityMatrix.Core/Extensions/EnumAttributes.cs

@ -1,6 +1,4 @@
using System;
namespace StabilityMatrix.Extensions;
namespace StabilityMatrix.Core.Extensions;
public static class EnumAttributeExtensions
{

4
StabilityMatrix/Extensions/EnumConversion.cs → StabilityMatrix.Core/StabilityMatrix.Core/Extensions/EnumConversion.cs

@ -1,6 +1,4 @@
using System;
namespace StabilityMatrix.Extensions;
namespace StabilityMatrix.Core.Extensions;
public static class EnumConversionExtensions
{

5
StabilityMatrix/Extensions/EnumerableExtensions.cs → StabilityMatrix.Core/StabilityMatrix.Core/Extensions/EnumerableExtensions.cs

@ -1,7 +1,4 @@
using System.Collections.Generic;
using System.Linq;
namespace StabilityMatrix.Extensions;
namespace StabilityMatrix.Core.Extensions;
public static class EnumerableExtensions
{

7
StabilityMatrix/Extensions/LiteDBExtensions.cs → StabilityMatrix.Core/StabilityMatrix.Core/Extensions/LiteDBExtensions.cs

@ -1,12 +1,9 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Linq.Expressions;
using System.Linq.Expressions;
using System.Reflection;
using LiteDB;
using LiteDB.Async;
namespace StabilityMatrix.Extensions;
namespace StabilityMatrix.Core.Extensions;
// ReSharper disable once InconsistentNaming
public static class LiteDBExtensions

8
StabilityMatrix/Helper/Cache/GithubApiCache.cs → StabilityMatrix.Core/StabilityMatrix.Core/Helper/Cache/GithubApiCache.cs

@ -1,11 +1,7 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using Microsoft.Extensions.Caching.Memory;
using Microsoft.Extensions.Caching.Memory;
using Octokit;
namespace StabilityMatrix.Helper.Cache;
namespace StabilityMatrix.Core.Helper.Cache;
public class GithubApiCache : IGithubApiCache
{

7
StabilityMatrix/Helper/Cache/IGithubApiCache.cs → StabilityMatrix.Core/StabilityMatrix.Core/Helper/Cache/IGithubApiCache.cs

@ -1,10 +1,7 @@
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using Octokit;
using Octokit;
using Refit;
namespace StabilityMatrix.Helper.Cache;
namespace StabilityMatrix.Core.Helper.Cache;
public interface IGithubApiCache
{

5
StabilityMatrix/Helper/Cache/LRUCache.cs → StabilityMatrix.Core/StabilityMatrix.Core/Helper/Cache/LRUCache.cs

@ -1,7 +1,6 @@
using System.Collections.Generic;
using System.Runtime.CompilerServices;
using System.Runtime.CompilerServices;
namespace StabilityMatrix.Helper.Cache;
namespace StabilityMatrix.Core.Helper.Cache;
// ReSharper disable once InconsistentNaming
public class LRUCache<TK,TV> where TK : notnull

5
StabilityMatrix/Helper/Expressions.cs → StabilityMatrix.Core/StabilityMatrix.Core/Helper/Expressions.cs

@ -1,8 +1,7 @@
using System;
using System.Linq.Expressions;
using System.Linq.Expressions;
using System.Reflection;
namespace StabilityMatrix.Helper;
namespace StabilityMatrix.Core.Helper;
public static class Expressions
{

7
StabilityMatrix/Helper/FileHash.cs → StabilityMatrix.Core/StabilityMatrix.Core/Helper/FileHash.cs

@ -1,12 +1,9 @@
using System;
using System.Buffers;
using System.IO;
using System.Buffers;
using System.Security.Cryptography;
using System.Threading.Tasks;
using Blake3;
using StabilityMatrix.Core.Models.Progress;
namespace StabilityMatrix.Helper;
namespace StabilityMatrix.Core.Helper;
public static class FileHash
{

9
StabilityMatrix/Helper/FileTransfers.cs → StabilityMatrix.Core/StabilityMatrix.Core/Helper/FileTransfers.cs

@ -1,12 +1,7 @@
using System;
using System.Buffers;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Threading.Tasks;
using System.Buffers;
using StabilityMatrix.Core.Models.Progress;
namespace StabilityMatrix.Helper;
namespace StabilityMatrix.Core.Helper;
public static class FileTransfers
{

27
StabilityMatrix/Helper/HardwareHelper.cs → StabilityMatrix.Core/StabilityMatrix.Core/Helper/HardwareHelper.cs

@ -1,10 +1,6 @@
using System;
using System.Collections.Generic;
using System.Diagnostics.CodeAnalysis;
using System.Linq;
using Microsoft.Win32;
using Microsoft.Win32;
namespace StabilityMatrix.Helper;
namespace StabilityMatrix.Core.Helper;
public static class HardwareHelper
{
@ -82,25 +78,6 @@ public static class HardwareHelper
}
}
[SuppressMessage("ReSharper", "MemberCanBePrivate.Global")]
public static class Size
{
public const ulong KiB = 1024;
public const ulong MiB = KiB * 1024;
public const ulong GiB = MiB * 1024;
public static string FormatBytes(ulong bytes)
{
return bytes switch
{
< KiB => $"{bytes} B",
< MiB => $"{bytes / (double) KiB:0.0} KiB",
< GiB => $"{bytes / (double) MiB:0.0} MiB",
_ => $"{bytes / (double) GiB:0.0} GiB"
};
}
}
public enum Level
{
Unknown,

6
StabilityMatrix/Helper/MinimumDelay.cs → StabilityMatrix.Core/StabilityMatrix.Core/Helper/MinimumDelay.cs

@ -1,8 +1,6 @@
using System;
using System.Diagnostics;
using System.Threading.Tasks;
using System.Diagnostics;
namespace StabilityMatrix.Helper;
namespace StabilityMatrix.Core.Helper;
/// <summary>
/// Enforces a minimum delay if the function returns too quickly.

5
StabilityMatrix/Helper/ObjectHash.cs → StabilityMatrix.Core/StabilityMatrix.Core/Helper/ObjectHash.cs

@ -1,8 +1,7 @@
using System;
using System.Text;
using System.Text;
using System.Text.Json;
namespace StabilityMatrix.Helper;
namespace StabilityMatrix.Core.Helper;
public class ObjectHash
{

9
StabilityMatrix/Helper/ProcessRunner.cs → StabilityMatrix.Core/StabilityMatrix.Core/Helper/ProcessRunner.cs

@ -1,14 +1,9 @@
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
using System.Diagnostics;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
using NLog;
using StabilityMatrix.Core.Exceptions;
namespace StabilityMatrix.Helper;
namespace StabilityMatrix.Core.Helper;
public static class ProcessRunner
{

7
StabilityMatrix/Helper/ProcessTracker.cs → StabilityMatrix.Core/StabilityMatrix.Core/Helper/ProcessTracker.cs

@ -1,10 +1,10 @@
using System;
using System.ComponentModel;
using System.ComponentModel;
using System.Diagnostics;
using System.Runtime.InteropServices;
using System.Runtime.Versioning;
using NLog;
namespace StabilityMatrix.Helper;
namespace StabilityMatrix.Core.Helper;
/// <summary>
/// Allows processes to be automatically killed if this parent process unexpectedly quits.
@ -12,6 +12,7 @@ namespace StabilityMatrix.Helper;
/// <remarks>References:
/// https://stackoverflow.com/a/4657392/386091
/// https://stackoverflow.com/a/9164742/386091 </remarks>
[SupportedOSPlatform("windows")]
public static class ProcessTracker
{
private static readonly Logger Logger = LogManager.GetCurrentClassLogger();

22
StabilityMatrix.Core/StabilityMatrix.Core/Helper/Size.cs

@ -0,0 +1,22 @@
using System.Diagnostics.CodeAnalysis;
namespace StabilityMatrix.Core.Helper;
[SuppressMessage("ReSharper", "MemberCanBePrivate.Global")]
public static class Size
{
public const ulong KiB = 1024;
public const ulong MiB = KiB * 1024;
public const ulong GiB = MiB * 1024;
public static string FormatBytes(ulong bytes)
{
return bytes switch
{
< KiB => $"{bytes} B",
< MiB => $"{bytes / (double) KiB:0.0} KiB",
< GiB => $"{bytes / (double) MiB:0.0} MiB",
_ => $"{bytes / (double) GiB:0.0} GiB"
};
}
}

4
StabilityMatrix/Helper/SystemInfo.cs → StabilityMatrix.Core/StabilityMatrix.Core/Helper/SystemInfo.cs

@ -1,8 +1,8 @@
using System.Runtime.InteropServices;
namespace StabilityMatrix.Helper;
namespace StabilityMatrix.Core.Helper;
internal static class SystemInfo
public static class SystemInfo
{
[DllImport("UXTheme.dll", SetLastError = true, EntryPoint = "#138")]
public static extern bool ShouldUseDarkMode();

6
StabilityMatrix/Helper/Utilities.cs → StabilityMatrix.Core/StabilityMatrix.Core/Helper/Utilities.cs

@ -1,8 +1,6 @@
using System.IO;
using System.Linq;
using System.Reflection;
using System.Reflection;
namespace StabilityMatrix.Helper;
namespace StabilityMatrix.Core.Helper;
public static class Utilities
{

2
StabilityMatrix/Models/Configs/DebugOptions.cs → StabilityMatrix.Core/StabilityMatrix.Core/Models/Configs/DebugOptions.cs

@ -1,4 +1,4 @@
namespace StabilityMatrix.Models.Configs;
namespace StabilityMatrix.Core.Models.Configs;
public class DebugOptions
{

6
StabilityMatrix/Models/FileInterfaces/DirectoryPath.cs → StabilityMatrix.Core/StabilityMatrix.Core/Models/FileInterfaces/DirectoryPath.cs

@ -1,8 +1,4 @@
using System.IO;
using System.Linq;
using System.Threading.Tasks;
namespace StabilityMatrix.Models.FileInterfaces;
namespace StabilityMatrix.Core.Models.FileInterfaces;
public class DirectoryPath : FileSystemPath, IPathObject
{

5
StabilityMatrix/Models/FileInterfaces/FilePath.cs → StabilityMatrix.Core/StabilityMatrix.Core/Models/FileInterfaces/FilePath.cs

@ -1,9 +1,6 @@
using System.Diagnostics.CodeAnalysis;
using System.IO;
using System.Threading;
using System.Threading.Tasks;
namespace StabilityMatrix.Models.FileInterfaces;
namespace StabilityMatrix.Core.Models.FileInterfaces;
[SuppressMessage("ReSharper", "MemberCanBePrivate.Global")]
public class FilePath : FileSystemPath, IPathObject

5
StabilityMatrix/Models/FileInterfaces/FileSystemPath.cs → StabilityMatrix.Core/StabilityMatrix.Core/Models/FileInterfaces/FileSystemPath.cs

@ -1,7 +1,4 @@
using System;
using System.IO;
namespace StabilityMatrix.Models.FileInterfaces;
namespace StabilityMatrix.Core.Models.FileInterfaces;
public class FileSystemPath : IEquatable<FileSystemPath>, IEquatable<string>
{

4
StabilityMatrix/Models/FileInterfaces/IPathObject.cs → StabilityMatrix.Core/StabilityMatrix.Core/Models/FileInterfaces/IPathObject.cs

@ -1,6 +1,4 @@
using System.Threading.Tasks;
namespace StabilityMatrix.Models.FileInterfaces;
namespace StabilityMatrix.Core.Models.FileInterfaces;
public interface IPathObject
{

2
StabilityMatrix/Models/FileSizeType.cs → StabilityMatrix.Core/StabilityMatrix.Core/Models/FileSizeType.cs

@ -1,6 +1,6 @@
using System.Globalization;
namespace StabilityMatrix.Models;
namespace StabilityMatrix.Core.Models;
public class FileSizeType
{

5
StabilityMatrix/Models/GlobalConfig.cs → StabilityMatrix.Core/StabilityMatrix.Core/Models/GlobalConfig.cs

@ -1,7 +1,6 @@
using System;
using StabilityMatrix.Models.FileInterfaces;
using StabilityMatrix.Core.Models.FileInterfaces;
namespace StabilityMatrix.Models;
namespace StabilityMatrix.Core.Models;
public static class GlobalConfig
{

12
StabilityMatrix/Models/InstalledPackage.cs → StabilityMatrix.Core/StabilityMatrix.Core/Models/InstalledPackage.cs

@ -1,11 +1,7 @@
using System;
using System.Collections.Generic;
using System.IO;
using System.Text.Json.Serialization;
using System.Threading.Tasks;
using StabilityMatrix.Helper;
namespace StabilityMatrix.Models;
using System.Text.Json.Serialization;
using StabilityMatrix.Core.Helper;
namespace StabilityMatrix.Core.Models;
/// <summary>
/// Profile information for a user-installed package.

9
StabilityMatrix/Models/LaunchOption.cs → StabilityMatrix.Core/StabilityMatrix.Core/Models/LaunchOption.cs

@ -1,9 +1,8 @@
using System;
using System.Text.Json.Serialization;
using StabilityMatrix.Converters.Json;
using StabilityMatrix.Helper;
using System.Text.Json.Serialization;
using StabilityMatrix.Core.Converters.Json;
using StabilityMatrix.Core.Helper;
namespace StabilityMatrix.Models;
namespace StabilityMatrix.Core.Models;
public class LaunchOption
{

2
StabilityMatrix/Models/LaunchOptionCard.cs → StabilityMatrix.Core/StabilityMatrix.Core/Models/LaunchOptionCard.cs

@ -1,6 +1,6 @@
using System.Collections.ObjectModel;
namespace StabilityMatrix.Models;
namespace StabilityMatrix.Core.Models;
public class LaunchOptionCard
{

5
StabilityMatrix/Models/LaunchOptionDefinition.cs → StabilityMatrix.Core/StabilityMatrix.Core/Models/LaunchOptionDefinition.cs

@ -1,7 +1,6 @@
using System.Collections.Generic;
using System.Text.Json.Serialization;
using System.Text.Json.Serialization;
namespace StabilityMatrix.Models;
namespace StabilityMatrix.Core.Models;
/// <summary>
/// Defines a launch option for a BasePackage.

2
StabilityMatrix/Models/LaunchOptionType.cs → StabilityMatrix.Core/StabilityMatrix.Core/Models/LaunchOptionType.cs

@ -1,4 +1,4 @@
namespace StabilityMatrix.Models;
namespace StabilityMatrix.Core.Models;
public enum LaunchOptionType
{

4
StabilityMatrix/Models/LicenseInfo.cs → StabilityMatrix.Core/StabilityMatrix.Core/Models/LicenseInfo.cs

@ -1,6 +1,4 @@
using System.Collections.Generic;
namespace StabilityMatrix.Models;
namespace StabilityMatrix.Core.Models;
public class LicenseInfo
{

2
StabilityMatrix/Models/LoadState.cs → StabilityMatrix.Core/StabilityMatrix.Core/Models/LoadState.cs

@ -1,4 +1,4 @@
namespace StabilityMatrix.Models;
namespace StabilityMatrix.Core.Models;
public enum LoadState
{

2
StabilityMatrix/Models/PackageVersion.cs → StabilityMatrix.Core/StabilityMatrix.Core/Models/PackageVersion.cs

@ -1,4 +1,4 @@
namespace StabilityMatrix.Models;
namespace StabilityMatrix.Core.Models;
public class PackageVersion
{

5
StabilityMatrix/Models/SharedFolderType.cs → StabilityMatrix.Core/StabilityMatrix.Core/Models/SharedFolderType.cs

@ -1,7 +1,6 @@
using System;
using System.Diagnostics.CodeAnalysis;
using System.Diagnostics.CodeAnalysis;
namespace StabilityMatrix.Models;
namespace StabilityMatrix.Core.Models;
[SuppressMessage("ReSharper", "InconsistentNaming")]
[SuppressMessage("ReSharper", "IdentifierTypo")]

5
StabilityMatrix/Models/TaskResult.cs → StabilityMatrix.Core/StabilityMatrix.Core/Models/TaskResult.cs

@ -1,7 +1,6 @@
using System;
using System.Diagnostics.CodeAnalysis;
using System.Diagnostics.CodeAnalysis;
namespace StabilityMatrix.Models;
namespace StabilityMatrix.Core.Models;
public readonly record struct TaskResult<T>
{

9
StabilityMatrix/Python/ArgParser.cs → StabilityMatrix.Core/StabilityMatrix.Core/Python/ArgParser.cs

@ -1,11 +1,8 @@
using System;
using System.Collections.Generic;
using System.Threading.Tasks;
using NLog;
using NLog;
using Python.Runtime;
using StabilityMatrix.Models;
using StabilityMatrix.Core.Models;
namespace StabilityMatrix.Python;
namespace StabilityMatrix.Core.Python;
/// <summary>
/// Extracts command arguments from Python source file.

7
StabilityMatrix/Python/IPyRunner.cs → StabilityMatrix.Core/StabilityMatrix.Core/Python/IPyRunner.cs

@ -1,9 +1,4 @@
using System;
using System.IO;
using System.Threading;
using System.Threading.Tasks;
namespace StabilityMatrix.Python;
namespace StabilityMatrix.Core.Python;
public interface IPyRunner
{

7
StabilityMatrix/Python/Interop/PyIOStream.cs → StabilityMatrix.Core/StabilityMatrix.Core/Python/Interop/PyIOStream.cs

@ -1,10 +1,7 @@
using System;
using System.Collections.Generic;
using System.Diagnostics.CodeAnalysis;
using System.IO;
using System.Diagnostics.CodeAnalysis;
using System.Text;
namespace StabilityMatrix.Python.Interop;
namespace StabilityMatrix.Core.Python.Interop;
/// <summary>
/// Implement the interface of the sys.stdout redirection

12
StabilityMatrix/Python/PyRunner.cs → StabilityMatrix.Core/StabilityMatrix.Core/Python/PyRunner.cs

@ -1,13 +1,9 @@
using System;
using System.IO;
using System.Threading;
using System.Threading.Tasks;
using NLog;
using NLog;
using Python.Runtime;
using StabilityMatrix.Helper;
using StabilityMatrix.Python.Interop;
using StabilityMatrix.Core.Helper;
using StabilityMatrix.Core.Python.Interop;
namespace StabilityMatrix.Python;
namespace StabilityMatrix.Core.Python;
public record struct PyVersionInfo(int Major, int Minor, int Micro, string ReleaseLevel, int Serial);

13
StabilityMatrix/Python/PyVenvRunner.cs → StabilityMatrix.Core/StabilityMatrix.Core/Python/PyVenvRunner.cs

@ -1,15 +1,10 @@
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.IO;
using System.Linq;
using System.Threading.Tasks;
using System.Diagnostics;
using NLog;
using Salaros.Configuration;
using StabilityMatrix.Helper;
using StabilityMatrix.Models.FileInterfaces;
using StabilityMatrix.Core.Helper;
using StabilityMatrix.Core.Models.FileInterfaces;
namespace StabilityMatrix.Python;
namespace StabilityMatrix.Core.Python;
/// <summary>
/// Python runner using a subprocess, mainly for venv support.

2
StabilityMatrix/ReparsePoints/DeviceIoControlCode.cs → StabilityMatrix.Core/StabilityMatrix.Core/ReparsePoints/DeviceIoControlCode.cs

@ -1,4 +1,4 @@
namespace StabilityMatrix.ReparsePoints;
namespace StabilityMatrix.Core.ReparsePoints;
internal enum DeviceIoControlCode : uint
{

6
StabilityMatrix/ReparsePoints/Junction.cs → StabilityMatrix.Core/StabilityMatrix.Core/ReparsePoints/Junction.cs

@ -1,13 +1,11 @@
using System;
using System.Diagnostics;
using System.Diagnostics;
using System.Diagnostics.CodeAnalysis;
using System.IO;
using System.Runtime.InteropServices;
using System.Runtime.Versioning;
using System.Text;
using Microsoft.Win32.SafeHandles;
namespace StabilityMatrix.ReparsePoints;
namespace StabilityMatrix.Core.ReparsePoints;
[SupportedOSPlatform("windows")]
public static class Junction

2
StabilityMatrix/ReparsePoints/ReparseDataBuffer.cs → StabilityMatrix.Core/StabilityMatrix.Core/ReparsePoints/ReparseDataBuffer.cs

@ -1,6 +1,6 @@
using System.Runtime.InteropServices;
namespace StabilityMatrix.ReparsePoints;
namespace StabilityMatrix.Core.ReparsePoints;
/// <summary>
/// Because the tag we're using is IO_REPARSE_TAG_MOUNT_POINT,

2
StabilityMatrix/ReparsePoints/Win32CreationDisposition.cs → StabilityMatrix.Core/StabilityMatrix.Core/ReparsePoints/Win32CreationDisposition.cs

@ -1,4 +1,4 @@
namespace StabilityMatrix.ReparsePoints;
namespace StabilityMatrix.Core.ReparsePoints;
internal enum Win32CreationDisposition : uint
{

14
StabilityMatrix/ReparsePoints/Win32ErrorCode.cs → StabilityMatrix.Core/StabilityMatrix.Core/ReparsePoints/Win32ErrorCode.cs

@ -1,36 +1,34 @@
using StabilityMatrix.Extensions;
namespace StabilityMatrix.ReparsePoints;
namespace StabilityMatrix.Core.ReparsePoints;
internal enum Win32ErrorCode
{
/// <summary>
/// The file or directory is not a reparse point.
/// ERROR_NOT_A_REPARSE_POINT
/// </summary>
[StringValue("ERROR_NOT_A_REPARSE_POINT")]
NotAReparsePoint = 4390,
/// <summary>
/// The reparse point attribute cannot be set because it conflicts with an existing attribute.
/// ERROR_REPARSE_ATTRIBUTE_CONFLICT
/// </summary>
[StringValue("ERROR_REPARSE_ATTRIBUTE_CONFLICT")]
ReparseAttributeConflict = 4391,
/// <summary>
/// The data present in the reparse point buffer is invalid.
/// ERROR_INVALID_REPARSE_DATA
/// </summary>
[StringValue("ERROR_INVALID_REPARSE_DATA")]
InvalidReparseData = 4392,
/// <summary>
/// The tag present in the reparse point buffer is invalid.
/// ERROR_REPARSE_TAG_INVALID
/// </summary>
[StringValue("ERROR_REPARSE_TAG_INVALID")]
ReparseTagInvalid = 4393,
/// <summary>
/// There is a mismatch between the tag specified in the request and the tag present in the reparse point.
/// ERROR_REPARSE_TAG_MISMATCH
/// </summary>
[StringValue("ERROR_REPARSE_TAG_MISMATCH")]
ReparseTagMismatch = 4394,
}

4
StabilityMatrix/ReparsePoints/Win32FileAccess.cs → StabilityMatrix.Core/StabilityMatrix.Core/ReparsePoints/Win32FileAccess.cs

@ -1,6 +1,4 @@
using System;
namespace StabilityMatrix.ReparsePoints;
namespace StabilityMatrix.Core.ReparsePoints;
[Flags]
internal enum Win32FileAccess : uint

5
StabilityMatrix/ReparsePoints/Win32FileAttribute.cs → StabilityMatrix.Core/StabilityMatrix.Core/ReparsePoints/Win32FileAttribute.cs

@ -1,7 +1,6 @@
using System;
using System.Diagnostics.CodeAnalysis;
using System.Diagnostics.CodeAnalysis;
namespace StabilityMatrix.ReparsePoints;
namespace StabilityMatrix.Core.ReparsePoints;
[Flags]
[SuppressMessage("ReSharper", "InconsistentNaming")]

4
StabilityMatrix/ReparsePoints/Win32FileShare.cs → StabilityMatrix.Core/StabilityMatrix.Core/ReparsePoints/Win32FileShare.cs

@ -1,6 +1,4 @@
using System;
namespace StabilityMatrix.ReparsePoints;
namespace StabilityMatrix.Core.ReparsePoints;
[Flags]
internal enum Win32FileShare : uint

22
StabilityMatrix.Core/StabilityMatrix.Core/StabilityMatrix.Core.csproj

@ -6,4 +6,26 @@
<Nullable>enable</Nullable>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="AsyncAwaitBestPractices" Version="6.0.6" />
<PackageReference Include="Blake3" Version="0.5.1" />
<PackageReference Include="LiteDB" Version="5.0.16" />
<PackageReference Include="LiteDB.Async" Version="0.1.6" />
<PackageReference Include="Microsoft.Extensions.Caching.Memory" Version="7.0.0" />
<PackageReference Include="Microsoft.Extensions.Options.ConfigurationExtensions" Version="7.0.0" />
<PackageReference Include="NLog" Version="5.2.2" />
<PackageReference Include="NLog.Extensions.Logging" Version="5.3.2" />
<PackageReference Include="Octokit" Version="7.0.1" />
<PackageReference Include="pythonnet" Version="3.0.1" />
<PackageReference Include="Refit" Version="7.0.0" />
<PackageReference Include="Refit.HttpClientFactory" Version="7.0.0" />
<PackageReference Include="Salaros.ConfigParser" Version="0.3.8" />
<PackageReference Include="Sentry.NLog" Version="3.33.1" />
<PackageReference Include="SharpCompress" Version="0.33.0" />
</ItemGroup>
<ItemGroup>
<Folder Include="Models\Settings\" />
</ItemGroup>
</Project>

3
StabilityMatrix.Tests/Models/InstalledPackageTests.cs

@ -1,4 +1,5 @@
using StabilityMatrix.Models;
using StabilityMatrix.Core.Models;
using StabilityMatrix.Models;
namespace StabilityMatrix.Tests.Models;

3
StabilityMatrix.Tests/Models/SharedFoldersTests.cs

@ -1,4 +1,5 @@
using StabilityMatrix.Extensions;
using StabilityMatrix.Core.Extensions;
using StabilityMatrix.Core.Models;
using StabilityMatrix.Models;
namespace StabilityMatrix.Tests.Models;

2
StabilityMatrix.Tests/Python/PyRunnerTests.cs

@ -1,5 +1,5 @@
using Python.Runtime;
using StabilityMatrix.Python;
using StabilityMatrix.Core.Python;
namespace StabilityMatrix.Tests.Python;

2
StabilityMatrix.Tests/ReparsePoints/JunctionTests.cs

@ -1,5 +1,5 @@
using Microsoft.VisualBasic;
using StabilityMatrix.ReparsePoints;
using StabilityMatrix.Core.ReparsePoints;
namespace StabilityMatrix.Tests.ReparsePoints;

6
StabilityMatrix/App.xaml.cs

@ -27,13 +27,13 @@ using Polly.Timeout;
using Refit;
using Sentry;
using StabilityMatrix.Api;
using StabilityMatrix.Core.Helper.Cache;
using StabilityMatrix.Core.Models.Configs;
using StabilityMatrix.Core.Python;
using StabilityMatrix.Database;
using StabilityMatrix.Helper;
using StabilityMatrix.Helper.Cache;
using StabilityMatrix.Models;
using StabilityMatrix.Models.Configs;
using StabilityMatrix.Models.Packages;
using StabilityMatrix.Python;
using StabilityMatrix.Services;
using StabilityMatrix.Updater;
using StabilityMatrix.ViewModels;

4
StabilityMatrix/Database/LiteDbContext.cs

@ -5,10 +5,10 @@ using System.Linq;
using System.Threading.Tasks;
using LiteDB.Async;
using Microsoft.Extensions.Options;
using StabilityMatrix.Extensions;
using StabilityMatrix.Core.Extensions;
using StabilityMatrix.Core.Models.Configs;
using StabilityMatrix.Helper;
using StabilityMatrix.Models.Api;
using StabilityMatrix.Models.Configs;
namespace StabilityMatrix.Database;

1
StabilityMatrix/Helper/ArchiveHelper.cs

@ -9,6 +9,7 @@ using System.Windows.Threading;
using NLog;
using SharpCompress.Common;
using SharpCompress.Readers;
using StabilityMatrix.Core.Helper;
using StabilityMatrix.Core.Models.Progress;
namespace StabilityMatrix.Helper;

1
StabilityMatrix/Helper/DialogFactory.cs

@ -3,6 +3,7 @@ using System.Linq;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using StabilityMatrix.Core.Models;
using StabilityMatrix.Models;
using StabilityMatrix.Services;
using StabilityMatrix.ViewModels;

1
StabilityMatrix/Helper/IDialogFactory.cs

@ -1,5 +1,6 @@
using System.Collections.Generic;
using System.Threading.Tasks;
using StabilityMatrix.Core.Models;
using StabilityMatrix.Models;
namespace StabilityMatrix.Helper;

1
StabilityMatrix/Helper/ISettingsManager.cs

@ -2,6 +2,7 @@
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq.Expressions;
using StabilityMatrix.Core.Models;
using StabilityMatrix.Models;
using StabilityMatrix.Models.Settings;
using Wpf.Ui.Controls.Window;

1
StabilityMatrix/Helper/ISnackbarService.cs

@ -1,5 +1,6 @@
using System;
using System.Threading.Tasks;
using StabilityMatrix.Core.Models;
using StabilityMatrix.Models;
using Wpf.Ui.Common;
using Wpf.Ui.Controls;

3
StabilityMatrix/Helper/PrerequisiteHelper.cs

@ -8,8 +8,9 @@ using System.Threading.Tasks;
using Microsoft.Extensions.Logging;
using Microsoft.Win32;
using Octokit;
using StabilityMatrix.Core.Helper;
using StabilityMatrix.Core.Models.Progress;
using StabilityMatrix.Python;
using StabilityMatrix.Core.Python;
using StabilityMatrix.Services;
namespace StabilityMatrix.Helper;

4
StabilityMatrix/Helper/SettingsManager.cs

@ -12,9 +12,11 @@ using System.Threading.Tasks;
using AsyncAwaitBestPractices;
using NLog;
using Refit;
using StabilityMatrix.Core.Helper;
using StabilityMatrix.Core.Models;
using StabilityMatrix.Core.Python;
using StabilityMatrix.Models;
using StabilityMatrix.Models.Settings;
using StabilityMatrix.Python;
using Wpf.Ui.Controls.Window;
namespace StabilityMatrix.Helper;

1
StabilityMatrix/Helper/SnackbarService.cs

@ -1,6 +1,7 @@
using System.Threading.Tasks;
using System;
using AsyncAwaitBestPractices;
using StabilityMatrix.Core.Models;
using StabilityMatrix.Models;
using StabilityMatrix.ViewModels;
using Wpf.Ui.Common;

4
StabilityMatrix/InstallerWindow.xaml

@ -20,14 +20,14 @@
xmlns:converters="clr-namespace:StabilityMatrix.Converters"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:models="clr-namespace:StabilityMatrix.Models"
xmlns:octokit="clr-namespace:Octokit;assembly=Octokit"
xmlns:packages="clr-namespace:StabilityMatrix.Models.Packages"
xmlns:system="clr-namespace:System;assembly=System.Runtime"
xmlns:ui="http://schemas.lepo.co/wpfui/2022/xaml"
xmlns:viewModels="clr-namespace:StabilityMatrix.ViewModels"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:xaml="clr-namespace:MdXaml;assembly=MdXaml">
xmlns:xaml="clr-namespace:MdXaml;assembly=MdXaml"
xmlns:models="clr-namespace:StabilityMatrix.Core.Models;assembly=StabilityMatrix.Core">
<ui:FluentWindow.Resources>
<converters:ValueConverterGroup x:Key="InvertAndVisibilitate">

2
StabilityMatrix/LaunchOptionsDialog.xaml

@ -16,7 +16,7 @@
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:local="clr-namespace:StabilityMatrix"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:models="clr-namespace:StabilityMatrix.Models"
xmlns:models="clr-namespace:StabilityMatrix.Core.Models;assembly=StabilityMatrix.Core"
xmlns:ui="http://schemas.lepo.co/wpfui/2022/xaml"
xmlns:viewModels="clr-namespace:StabilityMatrix.ViewModels"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">

1
StabilityMatrix/LaunchOptionsDialog.xaml.cs

@ -1,5 +1,6 @@
using System.Collections.Generic;
using System.Windows;
using StabilityMatrix.Core.Models;
using StabilityMatrix.Models;
using StabilityMatrix.ViewModels;
using Wpf.Ui.Contracts;

6
StabilityMatrix/LaunchPage.xaml

@ -14,10 +14,10 @@
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:designViewModels="clr-namespace:StabilityMatrix.DesignData"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:models="clr-namespace:StabilityMatrix.Models"
xmlns:models="clr-namespace:StabilityMatrix.Core.Models;assembly=StabilityMatrix.Core"
xmlns:terminal="clr-namespace:Simple.Wpf.Terminal;assembly=Simple.Wpf.Terminal"
xmlns:ui="http://schemas.lepo.co/wpfui/2022/xaml"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:terminal="clr-namespace:Simple.Wpf.Terminal;assembly=Simple.Wpf.Terminal">
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
<Page.Resources>
<BooleanToVisibilityConverter x:Key="BoolToVisConverter" />

1
StabilityMatrix/Models/Api/CivitModel.cs

@ -2,6 +2,7 @@
using System.Linq;
using System.Text.Json.Serialization;
using LiteDB;
using StabilityMatrix.Core.Models;
namespace StabilityMatrix.Models.Api;

5
StabilityMatrix/Models/Api/CivitModelType.cs

@ -1,7 +1,8 @@
using System.Diagnostics.CodeAnalysis;
using System.Text.Json.Serialization;
using StabilityMatrix.Converters.Json;
using StabilityMatrix.Extensions;
using StabilityMatrix.Core.Converters.Json;
using StabilityMatrix.Core.Extensions;
using StabilityMatrix.Core.Models;
namespace StabilityMatrix.Models.Api;

3
StabilityMatrix/Models/CheckpointFile.cs

@ -11,8 +11,9 @@ using AsyncAwaitBestPractices;
using CommunityToolkit.Mvvm.ComponentModel;
using CommunityToolkit.Mvvm.Input;
using NLog;
using StabilityMatrix.Core.Extensions;
using StabilityMatrix.Core.Helper;
using StabilityMatrix.Core.Models.Progress;
using StabilityMatrix.Extensions;
using StabilityMatrix.Helper;
namespace StabilityMatrix.Models;

6
StabilityMatrix/Models/CheckpointFolder.cs

@ -8,10 +8,12 @@ using System.Threading.Tasks;
using System.Windows;
using CommunityToolkit.Mvvm.ComponentModel;
using CommunityToolkit.Mvvm.Input;
using StabilityMatrix.Core.Extensions;
using StabilityMatrix.Core.Helper;
using StabilityMatrix.Core.Models;
using StabilityMatrix.Core.Models.FileInterfaces;
using StabilityMatrix.Core.Models.Progress;
using StabilityMatrix.Extensions;
using StabilityMatrix.Helper;
using StabilityMatrix.Models.FileInterfaces;
using StabilityMatrix.Services;
using StabilityMatrix.ViewModels;

3
StabilityMatrix/Models/GlobalUserSecrets.cs

@ -8,7 +8,8 @@ using System.Security.Cryptography;
using System.Security.Principal;
using System.Text.Json;
using System.Text.Json.Serialization;
using StabilityMatrix.Models.FileInterfaces;
using StabilityMatrix.Core.Models;
using StabilityMatrix.Core.Models.FileInterfaces;
namespace StabilityMatrix.Models;

2
StabilityMatrix/Models/ISharedFolders.cs

@ -1,4 +1,4 @@
using StabilityMatrix.Models.FileInterfaces;
using StabilityMatrix.Core.Models.FileInterfaces;
using StabilityMatrix.Models.Packages;
namespace StabilityMatrix.Models;

4
StabilityMatrix/Models/Packages/A3WebUI.cs

@ -6,9 +6,11 @@ using System.IO;
using System.Linq;
using System.Text.RegularExpressions;
using System.Threading.Tasks;
using StabilityMatrix.Core.Helper;
using StabilityMatrix.Core.Helper.Cache;
using StabilityMatrix.Core.Models;
using StabilityMatrix.Core.Models.Progress;
using StabilityMatrix.Helper;
using StabilityMatrix.Helper.Cache;
using StabilityMatrix.Services;
namespace StabilityMatrix.Models.Packages;

5
StabilityMatrix/Models/Packages/BaseGitPackage.cs

@ -7,10 +7,11 @@ using System.Linq;
using System.Threading.Tasks;
using NLog;
using Octokit;
using StabilityMatrix.Core.Helper.Cache;
using StabilityMatrix.Core.Models;
using StabilityMatrix.Core.Models.Progress;
using StabilityMatrix.Core.Python;
using StabilityMatrix.Helper;
using StabilityMatrix.Helper.Cache;
using StabilityMatrix.Python;
using StabilityMatrix.Services;
namespace StabilityMatrix.Models.Packages;

2
StabilityMatrix/Models/Packages/BasePackage.cs

@ -3,7 +3,9 @@ using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using Octokit;
using StabilityMatrix.Core.Models;
using StabilityMatrix.Core.Models.Progress;
using PackageVersion = StabilityMatrix.Core.Models.PackageVersion;
namespace StabilityMatrix.Models.Packages;

4
StabilityMatrix/Models/Packages/ComfyUI.cs

@ -6,9 +6,11 @@ using System.Linq;
using System.Text.RegularExpressions;
using System.Threading.Tasks;
using NLog;
using StabilityMatrix.Core.Helper;
using StabilityMatrix.Core.Helper.Cache;
using StabilityMatrix.Core.Models;
using StabilityMatrix.Core.Models.Progress;
using StabilityMatrix.Helper;
using StabilityMatrix.Helper.Cache;
using StabilityMatrix.Services;
namespace StabilityMatrix.Models.Packages;

3
StabilityMatrix/Models/Packages/DankDiffusion.cs

@ -1,8 +1,9 @@
using System;
using System.Collections.Generic;
using System.Threading.Tasks;
using StabilityMatrix.Core.Helper.Cache;
using StabilityMatrix.Core.Models;
using StabilityMatrix.Helper;
using StabilityMatrix.Helper.Cache;
using StabilityMatrix.Services;
namespace StabilityMatrix.Models.Packages;

6
StabilityMatrix/Models/Packages/VladAutomatic.cs

@ -7,10 +7,12 @@ using System.Linq;
using System.Text.RegularExpressions;
using System.Threading.Tasks;
using NLog;
using StabilityMatrix.Core.Helper;
using StabilityMatrix.Core.Helper.Cache;
using StabilityMatrix.Core.Models;
using StabilityMatrix.Core.Models.Progress;
using StabilityMatrix.Core.Python;
using StabilityMatrix.Helper;
using StabilityMatrix.Helper.Cache;
using StabilityMatrix.Python;
using StabilityMatrix.Services;
namespace StabilityMatrix.Models.Packages;

1
StabilityMatrix/Models/Settings/Settings.cs

@ -1,6 +1,7 @@
using System;
using System.Collections.Generic;
using System.Linq;
using StabilityMatrix.Core.Models;
using Wpf.Ui.Controls.Window;
namespace StabilityMatrix.Models.Settings;

7
StabilityMatrix/Models/SharedFolders.cs

@ -2,11 +2,12 @@
using System.Collections.Generic;
using System.IO;
using NLog;
using StabilityMatrix.Extensions;
using StabilityMatrix.Core.Extensions;
using StabilityMatrix.Core.Models;
using StabilityMatrix.Core.Models.FileInterfaces;
using StabilityMatrix.Core.ReparsePoints;
using StabilityMatrix.Helper;
using StabilityMatrix.Models.FileInterfaces;
using StabilityMatrix.Models.Packages;
using StabilityMatrix.ReparsePoints;
namespace StabilityMatrix.Models;

2
StabilityMatrix/PackageManagerPage.xaml

@ -12,7 +12,7 @@
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:models="clr-namespace:StabilityMatrix.Models"
xmlns:models="clr-namespace:StabilityMatrix.Core.Models;assembly=StabilityMatrix.Core"
xmlns:ui="http://schemas.lepo.co/wpfui/2022/xaml"
xmlns:viewModels="clr-namespace:StabilityMatrix.ViewModels"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">

2
StabilityMatrix/Updater/UpdateChannel.cs

@ -1,5 +1,5 @@
using System.Text.Json.Serialization;
using StabilityMatrix.Converters.Json;
using StabilityMatrix.Core.Converters.Json;
namespace StabilityMatrix.Updater;

4
StabilityMatrix/Updater/UpdateHelper.cs

@ -7,10 +7,10 @@ using System.Threading.Tasks;
using System.Windows.Threading;
using Microsoft.Extensions.Logging;
using Microsoft.Extensions.Options;
using StabilityMatrix.Core.Extensions;
using StabilityMatrix.Core.Models.Configs;
using StabilityMatrix.Core.Models.Progress;
using StabilityMatrix.Extensions;
using StabilityMatrix.Helper;
using StabilityMatrix.Models.Configs;
using StabilityMatrix.Services;
namespace StabilityMatrix.Updater;

6
StabilityMatrix/ViewModels/CheckpointBrowserCardViewModel.cs

@ -10,12 +10,14 @@ using AsyncAwaitBestPractices;
using CommunityToolkit.Mvvm.Input;
using NLog;
using Refit;
using StabilityMatrix.Core.Extensions;
using StabilityMatrix.Core.Helper;
using StabilityMatrix.Core.Models;
using StabilityMatrix.Core.Models.FileInterfaces;
using StabilityMatrix.Core.Models.Progress;
using StabilityMatrix.Extensions;
using StabilityMatrix.Helper;
using StabilityMatrix.Models;
using StabilityMatrix.Models.Api;
using StabilityMatrix.Models.FileInterfaces;
using StabilityMatrix.Services;
using Wpf.Ui.Controls;

4
StabilityMatrix/ViewModels/CheckpointBrowserViewModel.cs

@ -12,8 +12,10 @@ using System.Diagnostics;
using System.Net.Http;
using System.Windows.Data;
using StabilityMatrix.Api;
using StabilityMatrix.Core.Extensions;
using StabilityMatrix.Core.Helper;
using StabilityMatrix.Core.Models;
using StabilityMatrix.Database;
using StabilityMatrix.Extensions;
using StabilityMatrix.Helper;
using StabilityMatrix.Models;
using StabilityMatrix.Models.Api;

5
StabilityMatrix/ViewModels/DataDirectoryMigrationViewModel.cs

@ -5,10 +5,11 @@ using System.Threading.Tasks;
using CommunityToolkit.Mvvm.ComponentModel;
using CommunityToolkit.Mvvm.Input;
using NLog;
using StabilityMatrix.Core.Helper;
using StabilityMatrix.Core.Models.FileInterfaces;
using StabilityMatrix.Core.Python;
using StabilityMatrix.Helper;
using StabilityMatrix.Models;
using StabilityMatrix.Models.FileInterfaces;
using StabilityMatrix.Python;
namespace StabilityMatrix.ViewModels;

1
StabilityMatrix/ViewModels/FirstLaunchSetupViewModel.cs

@ -4,6 +4,7 @@ using AsyncAwaitBestPractices;
using CommunityToolkit.Mvvm.ComponentModel;
using CommunityToolkit.Mvvm.Input;
using StabilityMatrix.Controls;
using StabilityMatrix.Core.Helper;
using StabilityMatrix.Helper;
namespace StabilityMatrix.ViewModels;

5
StabilityMatrix/ViewModels/InstallerViewModel.cs

@ -11,11 +11,12 @@ using CommunityToolkit.Mvvm.ComponentModel;
using CommunityToolkit.Mvvm.Input;
using Microsoft.Extensions.Logging;
using Octokit;
using StabilityMatrix.Core.Models;
using StabilityMatrix.Core.Models.Progress;
using StabilityMatrix.Core.Python;
using StabilityMatrix.Helper;
using StabilityMatrix.Models;
using StabilityMatrix.Models.Packages;
using StabilityMatrix.Python;
using StabilityMatrix.Services;
using Wpf.Ui.Contracts;
using Wpf.Ui.Controls;
@ -24,7 +25,7 @@ using Wpf.Ui.Controls.Window;
using Application = System.Windows.Application;
using EventManager = StabilityMatrix.Helper.EventManager;
using ISnackbarService = StabilityMatrix.Helper.ISnackbarService;
using PackageVersion = StabilityMatrix.Models.PackageVersion;
using PackageVersion = StabilityMatrix.Core.Models.PackageVersion;
namespace StabilityMatrix.ViewModels;

3
StabilityMatrix/ViewModels/LaunchOptionsDialogViewModel.cs

@ -6,7 +6,8 @@ using System.Diagnostics;
using System.Linq;
using CommunityToolkit.Mvvm.ComponentModel;
using NLog;
using StabilityMatrix.Helper.Cache;
using StabilityMatrix.Core.Helper.Cache;
using StabilityMatrix.Core.Models;
using StabilityMatrix.Models;
namespace StabilityMatrix.ViewModels;

4
StabilityMatrix/ViewModels/LaunchViewModel.cs

@ -9,10 +9,12 @@ using CommunityToolkit.Mvvm.ComponentModel;
using CommunityToolkit.Mvvm.Input;
using Microsoft.Extensions.Logging;
using Microsoft.Toolkit.Uwp.Notifications;
using StabilityMatrix.Core.Helper;
using StabilityMatrix.Core.Models;
using StabilityMatrix.Core.Python;
using StabilityMatrix.Helper;
using StabilityMatrix.Models;
using StabilityMatrix.Models.Packages;
using StabilityMatrix.Python;
using Wpf.Ui.Contracts;
using Wpf.Ui.Controls.ContentDialogControl;
using EventManager = StabilityMatrix.Helper.EventManager;

3
StabilityMatrix/ViewModels/MainWindowViewModel.cs

@ -10,8 +10,9 @@ using AsyncAwaitBestPractices;
using CommunityToolkit.Mvvm.ComponentModel;
using CommunityToolkit.Mvvm.Input;
using Microsoft.Extensions.Options;
using StabilityMatrix.Core.Helper;
using StabilityMatrix.Core.Models.Configs;
using StabilityMatrix.Helper;
using StabilityMatrix.Models.Configs;
using StabilityMatrix.Services;
using StabilityMatrix.Updater;
using Wpf.Ui.Appearance;

3
StabilityMatrix/ViewModels/OneClickInstallViewModel.cs

@ -4,11 +4,12 @@ using System.Windows;
using CommunityToolkit.Mvvm.ComponentModel;
using CommunityToolkit.Mvvm.Input;
using Microsoft.Extensions.Logging;
using StabilityMatrix.Core.Models;
using StabilityMatrix.Core.Models.Progress;
using StabilityMatrix.Core.Python;
using StabilityMatrix.Helper;
using StabilityMatrix.Models;
using StabilityMatrix.Models.Packages;
using StabilityMatrix.Python;
using EventManager = StabilityMatrix.Helper.EventManager;
namespace StabilityMatrix.ViewModels;

1
StabilityMatrix/ViewModels/PackageManagerViewModel.cs

@ -11,6 +11,7 @@ using CommunityToolkit.Mvvm.ComponentModel;
using CommunityToolkit.Mvvm.Input;
using Microsoft.Extensions.Logging;
using Polly;
using StabilityMatrix.Core.Models;
using StabilityMatrix.Core.Models.Progress;
using Wpf.Ui.Contracts;
using Wpf.Ui.Controls;

1
StabilityMatrix/ViewModels/SelectInstallLocationsViewModel.cs

@ -9,6 +9,7 @@ using CommunityToolkit.Mvvm.ComponentModel;
using CommunityToolkit.Mvvm.Input;
using NLog;
using Ookii.Dialogs.Wpf;
using StabilityMatrix.Core.Helper;
using StabilityMatrix.Core.Models.Progress;
using StabilityMatrix.Helper;
using StabilityMatrix.Models.Settings;

4
StabilityMatrix/ViewModels/SettingsViewModel.cs

@ -20,11 +20,13 @@ using Ookii.Dialogs.Wpf;
using Polly.Timeout;
using Refit;
using StabilityMatrix.Api;
using StabilityMatrix.Core.Helper;
using StabilityMatrix.Core.Models;
using StabilityMatrix.Core.Models.Progress;
using StabilityMatrix.Core.Python;
using StabilityMatrix.Database;
using StabilityMatrix.Helper;
using StabilityMatrix.Models;
using StabilityMatrix.Python;
using Wpf.Ui.Appearance;
using Wpf.Ui.Contracts;
using Wpf.Ui.Controls;

3
StabilityMatrix/ViewModels/TextToImageViewModel.cs

@ -9,7 +9,8 @@ using CommunityToolkit.Mvvm.ComponentModel;
using CommunityToolkit.Mvvm.Input;
using Microsoft.Extensions.Logging;
using StabilityMatrix.Api;
using StabilityMatrix.Extensions;
using StabilityMatrix.Core.Extensions;
using StabilityMatrix.Core.Models;
using StabilityMatrix.Helper;
using StabilityMatrix.Models;
using StabilityMatrix.Models.Api;

1
StabilityMatrix/ViewModels/UpdateWindowViewModel.cs

@ -5,6 +5,7 @@ using System.Threading.Tasks;
using System.Windows;
using CommunityToolkit.Mvvm.ComponentModel;
using CommunityToolkit.Mvvm.Input;
using StabilityMatrix.Core.Helper;
using StabilityMatrix.Core.Models.Progress;
using StabilityMatrix.Helper;
using StabilityMatrix.Updater;

Loading…
Cancel
Save