GitHub Action
ps-docs
Generate documentation from Infrastructure as Code (IaC) using PSDocs. PSDocs allows you to dynamically generate markdown from infrastructure code artifacts. Use pre-build modules or build your own.
To learn about PSDocs and how you can build documentation dynamically see Getting started.
To get the latest stable release use:
- name: Generate docs
uses: Microsoft/ps-docs@v0.1.0
To get the latest bits use:
- name: Generate docs
uses: Microsoft/ps-docs@main
For a list of changes please see the change log.
- name: Generate docs
uses: Microsoft/ps-docs@main
with:
inputPath: string # Optional. The path PSDocs will look for files to input files.
modules: string # Optional. A comma separated list of modules to use containing document definitions.
source: string # Optional. An path containing definitions to use for generating documentation.
conventions: string # Optional. A comma separated list of conventions to use for generating documentation.
outputPath: string # Optional. The path to write documentation to.
path: string # Optional. The working directory PSDocs is run from.
prerelease: boolean # Optional. Determine if a pre-release module version is installed.
The path PSDocs will look for files to input files. Defaults to repository root.
A comma separated list of modules to use containing document definitions.
Modules are additional packages that can be installed from the PowerShell Gallery. PSDocs will install the latest stable version from the PowerShell Gallery automatically by default. Available modules.
To install pre-release module versions, use prerelease: true
.
An path containing definitions to use for generating documentation.
Defaults to .ps-docs/
.
Use this option to include document definitions that have not been packaged as a module.
A comma separated list of conventions to use for generating documentation.
Conventions are code blocks that provide extensibility and integration.
They can be included in .Doc.ps1
files from .ps-docs/
or modules.
See about_PSDocs_Conventions for more information.
The path to write documentation to.
The working directory PSDocs is run from. Defaults to repository root.
Options specified in ps-docs.yaml
from this directory will be used unless overridden by inputs.
Determine if a pre-release rules module version is installed.
When set to true
the latest pre-release or stable module version is installed.
If this input is not configured, invalid, or set to false
only stable module versions will be installed.
To use PSDocs:
- See Creating a workflow file.
- Reference
Microsoft/ps-docs@main
. For example:
name: CI
on: [push]
jobs:
docs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@main
- name: Generate docs
uses: Microsoft/ps-docs@main
- Run the workflow.
This project welcomes contributions and suggestions. Most contributions require you to agree to a Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us the rights to use your contribution. For details, visit https://cla.microsoft.com.
When you submit a pull request, a CLA-bot will automatically determine whether you need to provide a CLA and decorate the PR appropriately (e.g., label, comment). Simply follow the instructions provided by the bot. You will only need to do this once across all repositories using our CLA.
This project has adopted the Microsoft Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact opencode@microsoft.com with any additional questions or comments.
This project is licensed under the MIT License.