File tree Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Original file line number Diff line number Diff line change @@ -32,9 +32,6 @@ Setup(context =>
32
32
} ) ;
33
33
34
34
BuildParameters . Initialize ( Context ) ;
35
-
36
- // Cleanup build artifacts.
37
- DeleteDirectory ( buildArtifactsDirectory , new DeleteDirectorySettings { Recursive = true } ) ;
38
35
39
36
// Executed BEFORE the first task.
40
37
Information ( "Xer.Cqrs.CommandStack" ) ;
@@ -50,6 +47,13 @@ Setup(context =>
50
47
Information ( "Publish to myget: {0}" , BuildParameters . Instance . ShouldPublishMyGet ) ;
51
48
Information ( "Publish to nuget: {0}" , BuildParameters . Instance . ShouldPublishNuGet ) ;
52
49
Information ( "///////////////////////////////////////////////////////////////////////////////" ) ;
50
+
51
+ if ( DirectoryExists ( buildArtifactsDirectory ) )
52
+ {
53
+ // Cleanup build artifacts.
54
+ Information ( $ "Cleaning up { buildArtifactsDirectory } directory.") ;
55
+ DeleteDirectory ( buildArtifactsDirectory , new DeleteDirectorySettings { Recursive = true } ) ;
56
+ }
53
57
} ) ;
54
58
55
59
Teardown ( context =>
You can’t perform that action at this time.
0 commit comments