@@ -28,10 +28,10 @@ public HelpInfo GetHelp()
28
28
{
29
29
return new HelpInfo
30
30
{
31
- Examples = new [ ]
32
- {
31
+ Examples =
32
+ [
33
33
new Example ( Name )
34
- }
34
+ ]
35
35
} ;
36
36
}
37
37
}
@@ -48,10 +48,10 @@ public HelpInfo GetHelp()
48
48
{
49
49
return new HelpInfo
50
50
{
51
- Examples = new [ ]
52
- {
51
+ Examples =
52
+ [
53
53
new Example ( Name ) . WithMsBuildArgument ( "Configuration" , "Debug" )
54
- }
54
+ ]
55
55
} ;
56
56
}
57
57
}
@@ -68,10 +68,10 @@ public HelpInfo GetHelp()
68
68
{
69
69
return new HelpInfo
70
70
{
71
- Examples = new [ ]
72
- {
71
+ Examples =
72
+ [
73
73
new Example ( Name )
74
- }
74
+ ]
75
75
} ;
76
76
}
77
77
}
@@ -88,12 +88,12 @@ public HelpInfo GetHelp()
88
88
{
89
89
return new HelpInfo
90
90
{
91
- Examples = new [ ]
92
- {
91
+ Examples =
92
+ [
93
93
new Example ( Name )
94
94
. WithArgument ( KnownOptions . Exclusive )
95
95
. WithArgument ( KnownOptions . Verbosity , "Diagnostic" )
96
- }
96
+ ]
97
97
} ;
98
98
}
99
99
}
@@ -145,68 +145,68 @@ public HelpInfo GetHelp()
145
145
{
146
146
return new HelpInfo
147
147
{
148
- Examples = new [ ]
149
- {
148
+ Examples =
149
+ [
150
150
new Example ( Name )
151
151
. WithMsBuildArgument ( "VersionPrefix" , "0.1.1729" )
152
152
. WithMsBuildArgument ( "VersionSuffix" , "preview" ) ,
153
153
new Example ( Name ) . WithArgument ( KnownOptions . Stable )
154
- }
154
+ ]
155
155
} ;
156
156
}
157
157
}
158
158
159
159
[ TaskName ( Name ) ]
160
- [ TaskDescription ( "Update generated documentation files" ) ]
161
- public class DocsUpdateTask : FrostingTask < BuildContext > , IHelpProvider
160
+ [ TaskDescription ( "Fetch changelog files" ) ]
161
+ public class DocsFetchTask : FrostingTask < BuildContext > , IHelpProvider
162
162
{
163
- private const string Name = "docs-update " ;
164
- public override void Run ( BuildContext context ) => context . DocumentationRunner . Update ( ) ;
163
+ private const string Name = "docs-fetch " ;
164
+ public override void Run ( BuildContext context ) => context . DocumentationRunner . Fetch ( ) ;
165
165
166
166
public HelpInfo GetHelp ( )
167
167
{
168
168
return new HelpInfo
169
169
{
170
170
Description = $ "This task updates the following files:\n " +
171
- $ "* README.md (the number of dependent projects number) \n " +
171
+ $ "* Clones branch 'docs-changelog' to docs/_changelog \n " +
172
172
$ "* Last changelog footer (if { KnownOptions . Stable . CommandLineName } is specified)\n " +
173
173
$ "* All changelog details in docs/_changelog\n " +
174
- $ " (This dir is a cloned version of this repo from branch { Repo . ChangelogDetailsBranch } )",
175
- Options = new IOption [ ] { KnownOptions . DocsPreview , KnownOptions . DocsDepth } ,
176
- EnvironmentVariables = new [ ] { EnvVar . GitHubToken } ,
177
- Examples = new [ ]
178
- {
174
+ $ " (This dir is a cloned version of this repo from branch { Repo . ChangelogBranch } )",
175
+ Options = [ KnownOptions . DocsPreview , KnownOptions . DocsDepth ] ,
176
+ EnvironmentVariables = [ EnvVar . GitHubToken ] ,
177
+ Examples =
178
+ [
179
179
new Example ( Name )
180
180
. WithArgument ( KnownOptions . DocsDepth , "3" )
181
181
. WithArgument ( KnownOptions . DocsPreview )
182
- }
182
+ ]
183
183
} ;
184
184
}
185
185
}
186
186
187
187
[ TaskName ( Name ) ]
188
- [ TaskDescription ( "Prepare auxiliary documentation files" ) ]
189
- public class DocsPrepareTask : FrostingTask < BuildContext > , IHelpProvider
188
+ [ TaskDescription ( "Generate auxiliary documentation files" ) ]
189
+ public class DocsGenerateTask : FrostingTask < BuildContext > , IHelpProvider
190
190
{
191
- private const string Name = "docs-prepare " ;
192
- public override void Run ( BuildContext context ) => context . DocumentationRunner . Prepare ( ) ;
191
+ private const string Name = "docs-generate " ;
192
+ public override void Run ( BuildContext context ) => context . DocumentationRunner . Generate ( ) ;
193
193
194
194
public HelpInfo GetHelp ( )
195
195
{
196
196
return new HelpInfo
197
197
{
198
- Options = new IOption [ ] { KnownOptions . DocsPreview } ,
199
- Examples = new [ ]
200
- {
198
+ Options = [ KnownOptions . DocsPreview ] ,
199
+ Examples =
200
+ [
201
201
new Example ( Name ) . WithArgument ( KnownOptions . DocsPreview )
202
- }
202
+ ]
203
203
} ;
204
204
}
205
205
}
206
206
207
207
[ TaskName ( Name ) ]
208
208
[ TaskDescription ( "Build final documentation" ) ]
209
- [ IsDependentOn ( typeof ( DocsPrepareTask ) ) ]
209
+ [ IsDependentOn ( typeof ( DocsGenerateTask ) ) ]
210
210
public class DocsBuildTask : FrostingTask < BuildContext > , IHelpProvider
211
211
{
212
212
private const string Name = "docs-build" ;
@@ -215,19 +215,20 @@ public class DocsBuildTask : FrostingTask<BuildContext>, IHelpProvider
215
215
public HelpInfo GetHelp ( ) => new ( )
216
216
{
217
217
Description = "The 'build' task should be run manually to build api docs" ,
218
- Options = new IOption [ ] { KnownOptions . DocsPreview } ,
219
- Examples = new [ ]
220
- {
218
+ Options = [ KnownOptions . DocsPreview ] ,
219
+ Examples =
220
+ [
221
221
new Example ( Name ) . WithArgument ( KnownOptions . DocsPreview )
222
- }
222
+ ]
223
223
} ;
224
224
}
225
225
226
226
[ TaskName ( Name ) ]
227
227
[ TaskDescription ( "Release new version" ) ]
228
228
[ IsDependentOn ( typeof ( BuildTask ) ) ]
229
229
[ IsDependentOn ( typeof ( PackTask ) ) ]
230
- [ IsDependentOn ( typeof ( DocsUpdateTask ) ) ]
230
+ [ IsDependentOn ( typeof ( DocsFetchTask ) ) ]
231
+ [ IsDependentOn ( typeof ( DocsGenerateTask ) ) ]
231
232
[ IsDependentOn ( typeof ( DocsBuildTask ) ) ]
232
233
public class ReleaseTask : FrostingTask < BuildContext > , IHelpProvider
233
234
{
@@ -236,17 +237,17 @@ public class ReleaseTask : FrostingTask<BuildContext>, IHelpProvider
236
237
237
238
public HelpInfo GetHelp ( ) => new ( )
238
239
{
239
- Options = new IOption [ ] { KnownOptions . NextVersion , KnownOptions . Push } ,
240
- EnvironmentVariables = new [ ] { EnvVar . GitHubToken , EnvVar . NuGetToken } ,
241
- Examples = new [ ]
242
- {
240
+ Options = [ KnownOptions . NextVersion , KnownOptions . Push ] ,
241
+ EnvironmentVariables = [ EnvVar . GitHubToken , EnvVar . NuGetToken ] ,
242
+ Examples =
243
+ [
243
244
new Example ( Name )
244
245
. WithArgument ( KnownOptions . Stable )
245
246
. WithArgument ( KnownOptions . NextVersion , "0.1.1729" )
246
247
. WithArgument ( KnownOptions . Push ) ,
247
248
new Example ( Name )
248
249
. WithArgument ( KnownOptions . Stable )
249
250
. WithArgument ( KnownOptions . Push )
250
- }
251
+ ]
251
252
} ;
252
253
}
0 commit comments