From: Ardis Lu Date: Mon, 24 Oct 2022 02:32:35 +0000 (-0700) Subject: Add documentation CI X-Git-Url: https://git.ardis.lu/?a=commitdiff_plain;h=814c071286de12f491a6c8da7dd31120140c3952;p=ArdisUtilities Add documentation CI --- diff --git a/.github/workflows/make-docs.yml b/.github/workflows/make-docs.yml new file mode 100644 index 0000000..99ff5e9 --- /dev/null +++ b/.github/workflows/make-docs.yml @@ -0,0 +1,33 @@ +name: Documentation CI + +on: + push: + branches: + - main + paths: + - "ArdisUtilities/ArdisUtilities.psd1" + - "ArdisUtilities/ArdisUtilities.psm1" + - ".github/workflows/make-docs.yml" + +jobs: + make-docs: + runs-on: windows-latest + steps: + - name: Checkout repository + uses: actions/checkout@v2 + + - name: Build README.md + shell: pwsh + run: | + Import-Module ./ArdisUtilities/ -Force + Get-Command -Module ArdisUtilities | Get-HelpAsMarkdown | Out-File -FilePath ./README.md + + - name: Push README.md to the orphan docs branch + run: | + git config user.name github-actions[bot] + git config user.email 41898282+github-actions[bot]@users.noreply.github.com + git checkout --orphan docs + git reset + git add -f README.md + git commit -m "Build README.md" + git push -f --set-upstream origin docs