diff --git a/.editorconfig b/.editorconfig
index 4d055997..62112f6e 100644
--- a/.editorconfig
+++ b/.editorconfig
@@ -26,6 +26,10 @@ dotnet_style_operator_placement_when_wrapping = beginning_of_line
tab_width = 4
end_of_line = crlf
+[*.{csproj,props}]
+indent_style = space
+tab_width = 2
+indent_size = 2
[*.cs]
diff --git a/.gitignore b/.gitignore
index 1dd71468..568b508b 100644
--- a/.gitignore
+++ b/.gitignore
@@ -6,6 +6,7 @@
*.user
*.userosscache
*.sln.docstates
+.idea/**/
# User-specific files (MonoDevelop/Xamarin Studio)
*.userprefs
diff --git a/Directory.Packages.props b/Directory.Packages.props
new file mode 100644
index 00000000..b479579d
--- /dev/null
+++ b/Directory.Packages.props
@@ -0,0 +1,34 @@
+
+
+ true
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/cake/Build.csproj b/cake/Build.csproj
index 890065de..00d049da 100644
--- a/cake/Build.csproj
+++ b/cake/Build.csproj
@@ -1,25 +1,25 @@
-
- Exe
- net8.0
- true
+
+ Exe
+ net9.0
+ true
-
- $(MSBuildProjectDirectory)
-
+
+ $(MSBuildProjectDirectory)
+
-
-
-
-
-
-
-
- all
- runtime; build; native; contentfiles; analyzers; buildtransitive
-
-
-
-
-
+
+
+
+
+
+
+
+ all
+ runtime; build; native; contentfiles; analyzers; buildtransitive
+
+
+
+
+
diff --git a/cake/Program.cs b/cake/Program.cs
index 7664126f..01fd3c91 100644
--- a/cake/Program.cs
+++ b/cake/Program.cs
@@ -9,11 +9,11 @@ public static int Main(string[] args)
{
return new CakeHost()
.InstallTool(new Uri("nuget:?package=Codecov&version=1.13.0"))
- .InstallTool(new Uri("nuget:?package=NUnit.ConsoleRunner&version=3.16.3"))
- .InstallTool(new Uri("nuget:?package=ReportGenerator&version=5.2.0"))
+ .InstallTool(new Uri("nuget:?package=NUnit.ConsoleRunner&version=3.18.3"))
+ .InstallTool(new Uri("nuget:?package=ReportGenerator&version=5.4.1"))
.InstallTool(new Uri("nuget:?package=GitVersion.CommandLine&version=5.12.0"))
- .InstallTool(new Uri("nuget:?package=Microsoft.CodeCoverage&version=17.8.0"))
- .InstallTool(new Uri("nuget:?package=nuget.commandline&version=6.8.0"))
+ .InstallTool(new Uri("nuget:?package=nuget.commandline&version=6.12.1"))
+ .InstallTool(new Uri("nuget:?package=dotnet-coverage&version=17.13.1"))
.UseContext()
.UseLifetime()
.UseWorkingDirectory("..")
diff --git a/cake/Tasks/CoberturaReport.cs b/cake/Tasks/CoberturaReport.cs
index f98885cc..122d467b 100644
--- a/cake/Tasks/CoberturaReport.cs
+++ b/cake/Tasks/CoberturaReport.cs
@@ -11,13 +11,13 @@ public sealed class CoberturaReport : FrostingTask
{
public override void Run(BuildContext context)
{
- context.MergeReports("./Results/coverage/**/*.xml", ReportGeneratorReportType.Cobertura, "cobertura");
+ context.MergeReports("./results/coverage/**/*.xml", ReportGeneratorReportType.Cobertura, "cobertura");
}
public override bool ShouldRun(BuildContext context)
{
- return base.ShouldRun(context)
- && context.GetFiles("./Results/coverage/**/*.xml").Count > 0;
+ var files = context.GetFiles("./results/coverage/**/*.xml");
+ return files.Count > 0;
}
}
}
diff --git a/cake/Tasks/ConvertCoverage.cs b/cake/Tasks/ConvertCoverage.cs
index c568ba7c..51da2d61 100644
--- a/cake/Tasks/ConvertCoverage.cs
+++ b/cake/Tasks/ConvertCoverage.cs
@@ -12,27 +12,31 @@ public sealed class ConvertCoverage : FrostingTask
{
public override void Run(BuildContext context)
{
+ var dotnetExe = context.Tools.Resolve("dotnet.exe");
+ var codeCoverageExe = context.Tools.Resolve("dotnet-coverage.dll");
+
foreach (var file in context.GetFiles($"{context.ResultsPath.FullPath}/coverage/**/*.coverage"))
{
- var codeCoverageExe = context.Tools.Resolve("CodeCoverage.exe");
var result = System.IO.Path.ChangeExtension(file.FullPath, ".xml");
var settings = new ProcessSettings()
.UseWorkingDirectory(context.ResultsPath)
.WithArguments(builder => builder
- .Append("analyze")
- .AppendSwitchQuoted(@"-output", ":", result)
+ .AppendQuoted(codeCoverageExe.FullPath)
+ .Append("merge")
+ .Append("--remove-input-files")
+ .AppendSwitchQuoted(@"--output", " ", result)
+ .AppendSwitch("--output-format", "xml")
.Append(file.FullPath)
);
- context.StartProcess(codeCoverageExe, settings);
+ context.StartProcess(dotnetExe.FullPath, settings);
}
}
public override bool ShouldRun(BuildContext context)
{
- return base.ShouldRun(context)
- && context.Tools.Resolve("CodeCoverage.exe") != null;
+ return context.Tools.Resolve("dotnet-coverage.dll") != null;
}
}
}
diff --git a/cake/Tasks/Default.cs b/cake/Tasks/Default.cs
index d23553f5..96e7810f 100644
--- a/cake/Tasks/Default.cs
+++ b/cake/Tasks/Default.cs
@@ -10,7 +10,5 @@ namespace Build
[IsDependentOn(typeof(PushNuget))]
[IsDependentOn(typeof(PushGithub))]
[IsDependentOn(typeof(PushLocally))]
- public sealed class Default : FrostingTask
- {
- }
+ public sealed class Default : FrostingTask;
}
diff --git a/cake/Tasks/HtmlReport.cs b/cake/Tasks/HtmlReport.cs
index 4e124a91..cb907d5a 100644
--- a/cake/Tasks/HtmlReport.cs
+++ b/cake/Tasks/HtmlReport.cs
@@ -11,13 +11,13 @@ public sealed class HtmlReport : FrostingTask
{
public override void Run(BuildContext context)
{
- context.MergeReports("./Results/coverage/**/*.xml", ReportGeneratorReportType.Html, "html");
+ context.MergeReports("./results/coverage/**/*.xml", ReportGeneratorReportType.Html, "html");
}
public override bool ShouldRun(BuildContext context)
{
- return base.ShouldRun(context)
- && context.GetFiles("./Results/coverage/**/*.xml").Count > 0;
+ var files = context.GetFiles("./results/coverage/**/*.xml");
+ return files.Count > 0;
}
}
}
diff --git a/cake/Tasks/TestAndUploadReport.cs b/cake/Tasks/TestAndUploadReport.cs
index 0d7959f7..e66c8989 100644
--- a/cake/Tasks/TestAndUploadReport.cs
+++ b/cake/Tasks/TestAndUploadReport.cs
@@ -4,7 +4,5 @@ namespace Build
{
[IsDependentOn(typeof(HtmlReport))]
[IsDependentOn(typeof(UploadCodecovReport))]
- public sealed class TestAndUploadReport : FrostingTask
- {
- }
+ public sealed class TestAndUploadReport : FrostingTask;
}
diff --git a/cake/Tasks/UploadCodecovReport.cs b/cake/Tasks/UploadCodecovReport.cs
index aaa87fe8..9d88a740 100644
--- a/cake/Tasks/UploadCodecovReport.cs
+++ b/cake/Tasks/UploadCodecovReport.cs
@@ -1,9 +1,6 @@
using Cake.Codecov;
using Cake.Common;
-using Cake.Common.Build;
-using Cake.Common.Diagnostics;
using Cake.Common.IO;
-using Cake.Core;
using Cake.Frosting;
namespace Build
@@ -15,10 +12,8 @@ public override void Run(BuildContext context)
{
var settings = new CodecovSettings()
{
- Required = true,
Verbose = true,
WorkingDirectory = context.CoberturaResultsPath,
- DisableNetwork = true,
Files = new[] { context.CoberturaResultFile.FullPath },
Token = context.EnvironmentVariable("CODECOV_TOKEN"),
};
diff --git a/global.json b/global.json
index f5daf0b5..975eec9f 100644
--- a/global.json
+++ b/global.json
@@ -1,6 +1,6 @@
{
"sdk": {
- "version": "8.0.300",
+ "version": "9.0.101",
"rollForward": "disable"
}
}
diff --git a/nuget.config b/nuget.config
index 2805dff3..4d688e2b 100644
--- a/nuget.config
+++ b/nuget.config
@@ -1,8 +1,15 @@
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/Directory.Build.targets b/src/Directory.Build.targets
index 0bbe8036..505eebc3 100644
--- a/src/Directory.Build.targets
+++ b/src/Directory.Build.targets
@@ -7,12 +7,12 @@
False
- 12.0
+ 13
..\..\MvvmScarletToolkit.ruleset
-
+
all
runtime; build; native; contentfiles; analyzers; buildtransitive
diff --git a/src/MvvmScarletToolkit.Abstractions/MvvmScarletToolkit.Abstractions.csproj b/src/MvvmScarletToolkit.Abstractions/MvvmScarletToolkit.Abstractions.csproj
index 349815c8..960147e1 100644
--- a/src/MvvmScarletToolkit.Abstractions/MvvmScarletToolkit.Abstractions.csproj
+++ b/src/MvvmScarletToolkit.Abstractions/MvvmScarletToolkit.Abstractions.csproj
@@ -1,20 +1,20 @@
-
- netstandard2.0
- Library
- enable
- MvvmScarletToolkit.Abstractions is part of the MvvmScarletToolkit framework, containing interfaces and extensions used by the rest of the framework.
- MvvmScarletToolkit,MVVM,C#,Toolkit,Scarlet,Library,.NET,OSS,OpenSource
-
+
+ netstandard2.0
+ Library
+ enable
+ MvvmScarletToolkit.Abstractions is part of the MvvmScarletToolkit framework, containing interfaces and extensions used by the rest of the framework.
+ MvvmScarletToolkit,MVVM,C#,Toolkit,Scarlet,Library,.NET,OSS,OpenSource
+
-
-
- all
- runtime; build; native; contentfiles; analyzers; buildtransitive
-
-
- all
- runtime; build; native; contentfiles; analyzers; buildtransitive
-
-
+
+
+ all
+ runtime; build; native; contentfiles; analyzers; buildtransitive
+
+
+ all
+ runtime; build; native; contentfiles; analyzers; buildtransitive
+
+
diff --git a/src/MvvmScarletToolkit.Commands/MvvmScarletToolkit.Commands.csproj b/src/MvvmScarletToolkit.Commands/MvvmScarletToolkit.Commands.csproj
index ab0c804c..91e36893 100644
--- a/src/MvvmScarletToolkit.Commands/MvvmScarletToolkit.Commands.csproj
+++ b/src/MvvmScarletToolkit.Commands/MvvmScarletToolkit.Commands.csproj
@@ -1,26 +1,26 @@
-
- netstandard2.0
- Library
- enable
- MvvmScarletToolkit.Commands is part of the MvvmScarletToolkit framework, containing asynchrnous and synchronous implementations of the ICommand interface for .NET.
- MvvmScarletToolkit,MVVM,C#,Toolkit,Scarlet,Library,.NET,OSS,OpenSource
-
+
+ netstandard2.0
+ Library
+ enable
+ MvvmScarletToolkit.Commands is part of the MvvmScarletToolkit framework, containing asynchrnous and synchronous implementations of the ICommand interface for .NET.
+ MvvmScarletToolkit,MVVM,C#,Toolkit,Scarlet,Library,.NET,OSS,OpenSource
+
-
-
+
+
-
- all
- runtime; build; native; contentfiles; analyzers; buildtransitive
-
-
- all
- runtime; build; native; contentfiles; analyzers; buildtransitive
-
-
+
+ all
+ runtime; build; native; contentfiles; analyzers; buildtransitive
+
+
+ all
+ runtime; build; native; contentfiles; analyzers; buildtransitive
+
+
-
-
-
+
+
+
diff --git a/src/MvvmScarletToolkit.Incubator/MvvmScarletToolkit.Incubator.csproj b/src/MvvmScarletToolkit.Incubator/MvvmScarletToolkit.Incubator.csproj
index 3fa42067..d6c1444d 100644
--- a/src/MvvmScarletToolkit.Incubator/MvvmScarletToolkit.Incubator.csproj
+++ b/src/MvvmScarletToolkit.Incubator/MvvmScarletToolkit.Incubator.csproj
@@ -1,18 +1,18 @@
-
- net6.0-windows;net7.0-windows;net8.0-windows
- Library
- true
- false
-
+
+ net8.0-windows;net9.0-windows
+ Library
+ true
+ false
+
-
-
-
-
-
+
+
+
+
+
-
-
-
+
+
+
diff --git a/src/MvvmScarletToolkit.Observables.Tests/MvvmScarletToolkit.Observables.Tests.csproj b/src/MvvmScarletToolkit.Observables.Tests/MvvmScarletToolkit.Observables.Tests.csproj
index c2349210..e5b61a71 100644
--- a/src/MvvmScarletToolkit.Observables.Tests/MvvmScarletToolkit.Observables.Tests.csproj
+++ b/src/MvvmScarletToolkit.Observables.Tests/MvvmScarletToolkit.Observables.Tests.csproj
@@ -1,25 +1,25 @@
-
- net6.0-windows;net7.0-windows;net8.0-windows
- false
-
+
+ net8.0-windows;net9.0-windows
+ false
+
-
-
-
+
+
+
-
-
-
-
- all
- runtime; build; native; contentfiles; analyzers
-
-
+
+
+
+
+ all
+ runtime; build; native; contentfiles; analyzers
+
+
-
-
-
-
-
+
+
+
+
+
diff --git a/src/MvvmScarletToolkit.Observables/MvvmScarletToolkit.Observables.csproj b/src/MvvmScarletToolkit.Observables/MvvmScarletToolkit.Observables.csproj
index 247c6a5e..cbeca151 100644
--- a/src/MvvmScarletToolkit.Observables/MvvmScarletToolkit.Observables.csproj
+++ b/src/MvvmScarletToolkit.Observables/MvvmScarletToolkit.Observables.csproj
@@ -1,27 +1,27 @@
-
- netstandard2.0
- Library
- enable
- MvvmScarletToolkit.Observables is part of the MvvmScarletToolkit framework, containing opinionated base classes for viewmodels of the MVVM pattern.
- MvvmScarletToolkit,MVVM,C#,Toolkit,Scarlet,Library,.NET,OSS,OpenSource
-
+
+ netstandard2.0
+ Library
+ enable
+ MvvmScarletToolkit.Observables is part of the MvvmScarletToolkit framework, containing opinionated base classes for viewmodels of the MVVM pattern.
+ MvvmScarletToolkit,MVVM,C#,Toolkit,Scarlet,Library,.NET,OSS,OpenSource
+
-
-
+
+
-
- all
- runtime; build; native; contentfiles; analyzers; buildtransitive
-
-
- all
- runtime; build; native; contentfiles; analyzers; buildtransitive
-
-
+
+ all
+ runtime; build; native; contentfiles; analyzers; buildtransitive
+
+
+ all
+ runtime; build; native; contentfiles; analyzers; buildtransitive
+
+
-
-
-
-
+
+
+
+
diff --git a/src/MvvmScarletToolkit.Wpf.Samples/MvvmScarletToolkit.Wpf.Samples.csproj b/src/MvvmScarletToolkit.Wpf.Samples/MvvmScarletToolkit.Wpf.Samples.csproj
index aafd4290..c507e810 100644
--- a/src/MvvmScarletToolkit.Wpf.Samples/MvvmScarletToolkit.Wpf.Samples.csproj
+++ b/src/MvvmScarletToolkit.Wpf.Samples/MvvmScarletToolkit.Wpf.Samples.csproj
@@ -1,53 +1,56 @@
-
- WinExe
- net8.0-windows
- true
- False
- false
- true
- true
- true
- win-x64
- true
-
-
-
-
-
-
-
-
-
-
-
- Never
-
-
- Never
-
-
- Never
-
-
- Never
-
-
- Never
-
-
- Never
-
-
+
+ WinExe
+ net9.0-windows
+ true
+ False
+ false
+ true
+ true
+ true
+ win-x64
+ true
+
+
+
+
+
+
+
+
+
+
+
+ Never
+
+
+ Never
+
+
+ Never
+
+
+ Never
+
+
+ Never
+
+
+ Never
+
+
-
-
-
-
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
diff --git a/src/MvvmScarletToolkit.Wpf.Tests/MvvmScarletToolkit.Wpf.Tests.csproj b/src/MvvmScarletToolkit.Wpf.Tests/MvvmScarletToolkit.Wpf.Tests.csproj
index ed8a7989..e914b9dd 100644
--- a/src/MvvmScarletToolkit.Wpf.Tests/MvvmScarletToolkit.Wpf.Tests.csproj
+++ b/src/MvvmScarletToolkit.Wpf.Tests/MvvmScarletToolkit.Wpf.Tests.csproj
@@ -1,26 +1,26 @@
-
- net6.0-windows;net7.0-windows;net8.0-windows
- false
-
+
+ net8.0-windows;net9.0-windows
+ false
+
-
-
-
+
+
+
-
-
+
+
-
-
- all
- runtime; build; native; contentfiles; analyzers
-
-
+
+
+ all
+ runtime; build; native; contentfiles; analyzers
+
+
-
-
-
-
-
+
+
+
+
+
diff --git a/src/MvvmScarletToolkit.Wpf/Features/FileSystemBrowser/MimeTypeResolvers/MagicNumberMimeTypeResolver.cs b/src/MvvmScarletToolkit.Wpf/Features/FileSystemBrowser/MimeTypeResolvers/MagicNumberMimeTypeResolver.cs
index 84993b2a..c66a4109 100644
--- a/src/MvvmScarletToolkit.Wpf/Features/FileSystemBrowser/MimeTypeResolvers/MagicNumberMimeTypeResolver.cs
+++ b/src/MvvmScarletToolkit.Wpf/Features/FileSystemBrowser/MimeTypeResolvers/MagicNumberMimeTypeResolver.cs
@@ -1,3 +1,4 @@
+using System;
using System.IO;
using System.Linq;
@@ -17,7 +18,7 @@ public string Get(IFileSystemFile fileInfo)
{
if (fileStream.Length >= 256)
{
- fileStream.Read(byteBuffer, 0, 256);
+ fileStream.ReadExactly(byteBuffer);
}
else
{
diff --git a/src/MvvmScarletToolkit.Wpf/Features/FileSystemBrowser/MimeTypeResolvers/UrlMonMimeTypeResolver.cs b/src/MvvmScarletToolkit.Wpf/Features/FileSystemBrowser/MimeTypeResolvers/UrlMonMimeTypeResolver.cs
index a340b33f..fd5c26ad 100644
--- a/src/MvvmScarletToolkit.Wpf/Features/FileSystemBrowser/MimeTypeResolvers/UrlMonMimeTypeResolver.cs
+++ b/src/MvvmScarletToolkit.Wpf/Features/FileSystemBrowser/MimeTypeResolvers/UrlMonMimeTypeResolver.cs
@@ -19,7 +19,7 @@ public sealed class UrlMonMimeTypeResolver : IMimeTypeResolver
{
if (fileStream.Length >= 256)
{
- fileStream.Read(byteBuffer, 0, 256);
+ fileStream.ReadExactly(byteBuffer);
}
else
{
diff --git a/src/MvvmScarletToolkit.Wpf/MvvmScarletToolkit.Wpf.csproj b/src/MvvmScarletToolkit.Wpf/MvvmScarletToolkit.Wpf.csproj
index e68f022e..9844db2a 100644
--- a/src/MvvmScarletToolkit.Wpf/MvvmScarletToolkit.Wpf.csproj
+++ b/src/MvvmScarletToolkit.Wpf/MvvmScarletToolkit.Wpf.csproj
@@ -1,29 +1,29 @@
-
- net6.0-windows;net7.0-windows;net8.0-windows
- Library
- true
- enable
- MvvmScarletToolkit.Implementations is part of the MvvmScarletToolkit framework, containing concrete implementations for WPF that have been abstracted away in the MvvmScarletToolkit.Abstractions library.
- MvvmScarletToolkit,MVVM,C#,Toolkit,Scarlet,WPF,Library,.NET,OSS,OpenSource
-
+
+ net8.0-windows;net9.0-windows
+ Library
+ true
+ enable
+ MvvmScarletToolkit.Implementations is part of the MvvmScarletToolkit framework, containing concrete implementations for WPF that have been abstracted away in the MvvmScarletToolkit.Abstractions library.
+ MvvmScarletToolkit,MVVM,C#,Toolkit,Scarlet,WPF,Library,.NET,OSS,OpenSource
+
-
-
- all
- runtime; build; native; contentfiles; analyzers; buildtransitive
-
-
- all
- runtime; build; native; contentfiles; analyzers; buildtransitive
-
+
+
+ all
+ runtime; build; native; contentfiles; analyzers; buildtransitive
+
+
+ all
+ runtime; build; native; contentfiles; analyzers; buildtransitive
+
-
-
+
+
-
-
-
-
-
+
+
+
+
+
diff --git a/src/MvvmScarletToolkit/MvvmScarletToolkit.csproj b/src/MvvmScarletToolkit/MvvmScarletToolkit.csproj
index cc88ebf0..c666a9cc 100644
--- a/src/MvvmScarletToolkit/MvvmScarletToolkit.csproj
+++ b/src/MvvmScarletToolkit/MvvmScarletToolkit.csproj
@@ -1,26 +1,26 @@
-
- netstandard2.0
- Library
- enable
- MvvmScarletToolkit is the main library of the MvvmScarletToolkit framework, containing classes and extensions that are being used everywhere else in the framework.
- MvvmScarletToolkit,MVVM,C#,Toolkit,Scarlet,Library,.NET,OSS,OpenSource
-
+
+ netstandard2.0
+ Library
+ enable
+ MvvmScarletToolkit is the main library of the MvvmScarletToolkit framework, containing classes and extensions that are being used everywhere else in the framework.
+ MvvmScarletToolkit,MVVM,C#,Toolkit,Scarlet,Library,.NET,OSS,OpenSource
+
-
-
+
+
-
- all
- runtime; build; native; contentfiles; analyzers; buildtransitive
-
-
- all
- runtime; build; native; contentfiles; analyzers; buildtransitive
-
-
+
+ all
+ runtime; build; native; contentfiles; analyzers; buildtransitive
+
+
+ all
+ runtime; build; native; contentfiles; analyzers; buildtransitive
+
+
-
-
-
+
+
+
diff --git a/src/SharedAssemblyInfo.cs b/src/SharedAssemblyInfo.cs
index d4907fb0..17e3ff01 100644
--- a/src/SharedAssemblyInfo.cs
+++ b/src/SharedAssemblyInfo.cs
@@ -7,7 +7,7 @@
[assembly: AssemblyCompany("SoftThorn")]
[assembly: AssemblyProduct("MvvmScarletToolkit")]
-[assembly: AssemblyCopyright("© 2023 Insire")]
+[assembly: AssemblyCopyright("© 2024 Insire")]
[assembly: AssemblyTrademark("")]
// Metadata Attributes
diff --git a/version.json b/version.json
index ce01f33c..7e0b5d23 100644
--- a/version.json
+++ b/version.json
@@ -1,6 +1,6 @@
{
"$schema": "https://raw.githubusercontent.com/dotnet/Nerdbank.GitVersioning/master/src/NerdBank.GitVersioning/version.schema.json",
- "version": "4.0",
+ "version": "5.0",
"publicReleaseRefSpec": [
"^refs/heads/master$",
"^refs/heads/v\\d+\\.\\d+$"