File tree Expand file tree Collapse file tree 2 files changed +6
-4
lines changed Expand file tree Collapse file tree 2 files changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -88,10 +88,7 @@ public async Task ResolveDirectoryTree(Cancel ctx)
88
88
public async Task GenerateAll ( Cancel ctx )
89
89
{
90
90
var generationState = GetPreviousGenerationState ( ) ;
91
- // always delete output folder on CI
92
- if ( ! string . IsNullOrEmpty ( Environment . GetEnvironmentVariable ( "GITHUB_ACTIONS" ) ) )
93
- DocumentationSet . ClearOutputDirectory ( ) ;
94
- else if ( ! Context . SkipMetadata && ( Context . Force || generationState == null ) )
91
+ if ( ! Context . SkipMetadata && ( Context . Force || generationState == null ) )
95
92
DocumentationSet . ClearOutputDirectory ( ) ;
96
93
97
94
if ( CompilationNotNeeded ( generationState , out var offendingFiles , out var outputSeenChanges ) )
Original file line number Diff line number Diff line change @@ -144,7 +144,12 @@ public async Task<int> Generate(
144
144
145
145
if ( runningOnCi )
146
146
await githubActionsService . SetOutputAsync ( "skip" , "false" ) ;
147
+
148
+ // always delete output folder on CI
147
149
var set = new DocumentationSet ( context , logger ) ;
150
+ if ( runningOnCi )
151
+ set . ClearOutputDirectory ( ) ;
152
+
148
153
149
154
if ( bool . TryParse ( githubActionsService . GetInput ( "metadata-only" ) , out var metaValue ) && metaValue )
150
155
metadataOnly ??= metaValue ;
You can’t perform that action at this time.
0 commit comments