diff --git a/Directory.Packages.props b/Directory.Packages.props index e6fd1aae..32a33670 100644 --- a/Directory.Packages.props +++ b/Directory.Packages.props @@ -16,6 +16,6 @@ - + diff --git a/build/build/Build.cs b/build/build/Build.cs index b89d8756..ba213d2c 100644 --- a/build/build/Build.cs +++ b/build/build/Build.cs @@ -5,7 +5,6 @@ using Nuke.Common.Tools.DotNet; using Nuke.Common.IO; using static Nuke.Common.IO.FileSystemTasks; -using static Nuke.Common.IO.PathConstruction; using static Nuke.Common.Tools.DotNet.DotNetTasks; class Build : NukeBuild @@ -48,7 +47,7 @@ protected override void OnBuildInitialized() VersionSuffix = VersionSuffix ?? ""; } - private void DeleteDirectories(IReadOnlyCollection directories) + private void DeleteDirectories(IReadOnlyCollection directories) { foreach (var directory in directories) { @@ -59,9 +58,9 @@ private void DeleteDirectories(IReadOnlyCollection directories) Target Clean => _ => _ .Executes(() => { - DeleteDirectories(GlobDirectories(SourceDirectory, "**/bin", "**/obj")); - DeleteDirectories(GlobDirectories(TestsDirectory, "**/bin", "**/obj")); - EnsureCleanDirectory(ArtifactsDirectory); + DeleteDirectories(SourceDirectory.GlobDirectories("**/bin", "**/obj")); + DeleteDirectories(TestsDirectory.GlobDirectories("**/bin", "**/obj")); + ArtifactsDirectory.CreateOrCleanDirectory(); }); Target Restore => _ => _