File tree Expand file tree Collapse file tree 3 files changed +26
-46
lines changed
Expand file tree Collapse file tree 3 files changed +26
-46
lines changed Original file line number Diff line number Diff line change 3838 env :
3939 CI : true
4040
41+ # Upload the static files
42+ - name : Upload documentation
43+ uses : actions/upload-pages-artifact@v2
44+ with :
45+ path : ./output
46+
47+ # GitHub Actions recommends deploying in a separate job.
48+ build-docs :
49+ runs-on : ubuntu-latest
50+ needs : build
51+ steps :
52+ - name : Deploy to GitHub Pages
53+ id : deployment
54+ uses : actions/deploy-pages@v2
55+
4156 analyze :
4257 runs-on : ubuntu-latest
4358 steps :
Load Diff This file was deleted.
Original file line number Diff line number Diff line change @@ -71,6 +71,8 @@ module dotnet =
7171
7272 let analyzers args = DotNet.exec id " fsharp-analyzers" args
7373
74+ let fsdocs args = DotNet.exec id " fsdocs" args
75+
7476let formatCode _ =
7577 let result = dotnet.fantomas " ."
7678
@@ -113,6 +115,12 @@ let analyze _ =
113115
114116 result.Errors |> Seq.iter Trace.traceError)
115117
118+ let generateDocs _ =
119+ [ " build" ; " --properties" ; $" Configuration=%s {configuration}" ]
120+ |> String.concat " "
121+ |> dotnet.fsdocs
122+ |> failOnBadExitAndPrint
123+
116124let clean _ =
117125 !! " bin" ++ " src/**/bin" ++ " tests/**/bin" ++ " src/**/obj" ++ " tests/**/obj"
118126 |> Shell.cleanDirs
@@ -258,6 +266,7 @@ let initTargets () =
258266 Target.create " Test" dotnetTest
259267 Target.create " CheckFormat" checkFormatCode
260268 Target.create " Analyze" analyze
269+ Target.create " GenerateDocs" generateDocs
261270 Target.create " AssemblyInfo" generateAssemblyInfo
262271 Target.create " DotnetPack" dotnetPack
263272 Target.create " PublishNuget" publishNuget
@@ -276,12 +285,14 @@ let initTargets () =
276285 // dotnet tools
277286 " Restore" ==>! " Analyze"
278287 " Restore" ==>! " CheckFormat"
288+ " Build" ==>! " GenerateDocs"
279289
280290 // publishing
281291 " AssemblyInfo" ==>! " PublishNuGet"
282292
283293 " Clean"
284294 ==> " CheckFormat"
295+ ==> " GenerateDocs"
285296 ==> " DotnetPack"
286297 ==> " PublishNuGet"
287298 ==> " GitRelease"
You can’t perform that action at this time.
0 commit comments