|
1 | | -# Publish to Azure DevOps Wiki |
| 1 | +# Publish to a wiki |
2 | 2 |
|
3 | | -Markdown generated with PSDocs for Azure can be published as wiki content for viewing with Azure DevOps. |
| 3 | +Markdown generated with PSDocs for Azure can be published as wiki content for |
| 4 | +viewing on Azure DevOps Wiki, GitHub Wiki, or any other Markdown-friendly |
| 5 | +documentation host. |
4 | 6 |
|
5 | 7 | !!! Abstract |
6 | | - This topic covers using a pipeline to publish markdown generated by PSDocs for Azure into an Azure DevOps Wiki. |
| 8 | + This topic covers using a pipeline to publish markdown generated by |
| 9 | + PSDocs for Azure to either an Azure DevOps Wiki or a GitHub Wiki / GitHub |
| 10 | + Pages site. |
7 | 11 |
|
8 | | -_Coming soon_. |
| 12 | +_Coming soon_ — detailed pipeline samples for both options. |
| 13 | + |
| 14 | +In the meantime, the general approach is: |
| 15 | + |
| 16 | +=== "Azure Pipelines" |
| 17 | + |
| 18 | + 1. Run `Invoke-PSDocument` against your templates in a build job, writing |
| 19 | + Markdown to a known output directory. |
| 20 | + 2. Publish the output as a pipeline artifact. |
| 21 | + 3. In a release stage, `git clone` the wiki repo (each Azure DevOps Wiki |
| 22 | + is backed by a Git repository), copy the artifact's Markdown into the |
| 23 | + wiki repo, commit, and push. |
| 24 | + |
| 25 | +=== "GitHub Actions" |
| 26 | + |
| 27 | + 1. Run `Invoke-PSDocument` against your templates in a workflow job, |
| 28 | + writing Markdown to a known output directory. |
| 29 | + 2. Either: |
| 30 | + - Push the Markdown to the repository's GitHub Wiki (the `*.wiki.git` |
| 31 | + repo) using a workflow such as |
| 32 | + [`Andrew-Chen-Wang/github-wiki-action`](https://github.com/Andrew-Chen-Wang/github-wiki-action), **or** |
| 33 | + - Publish the Markdown to GitHub Pages using the standard |
| 34 | + [`actions/deploy-pages`](https://github.com/actions/deploy-pages) |
| 35 | + flow with a static-site generator like MkDocs or Jekyll. |
0 commit comments