mirror of
https://github.com/ChrisTitusTech/winutil
synced 2026-04-06 14:48:31 +00:00
fix docs to create pr
This commit is contained in:
28
.github/workflows/docs.yaml
vendored
28
.github/workflows/docs.yaml
vendored
@@ -15,6 +15,7 @@ permissions:
|
|||||||
contents: write
|
contents: write
|
||||||
pages: write
|
pages: write
|
||||||
id-token: write
|
id-token: write
|
||||||
|
pull-requests: write
|
||||||
|
|
||||||
concurrency:
|
concurrency:
|
||||||
group: "pages"
|
group: "pages"
|
||||||
@@ -50,17 +51,24 @@ jobs:
|
|||||||
run: |
|
run: |
|
||||||
Set-Location tools
|
Set-Location tools
|
||||||
./devdocs-generator.ps1
|
./devdocs-generator.ps1
|
||||||
- name: Commit generated docs
|
|
||||||
|
- name: Create Pull Request 🚀
|
||||||
|
id: cpr
|
||||||
|
uses: peter-evans/create-pull-request@v6
|
||||||
|
with:
|
||||||
|
token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
commit-message: 'Update generated documentation'
|
||||||
|
title: 'chore: Update Generated Dev Docs'
|
||||||
|
body: 'Automated update of generated documentation from JSON sources'
|
||||||
|
branch: docs-update
|
||||||
|
delete-branch: true
|
||||||
|
labels: automated
|
||||||
|
|
||||||
|
- name: Check outputs
|
||||||
run: |
|
run: |
|
||||||
git config user.name "github-actions[bot]"
|
echo "Pull Request Number - ${{ steps.cpr.outputs.pull-request-number }}"
|
||||||
git config user.email "github-actions[bot]@users.noreply.github.com"
|
echo "Pull Request URL - ${{ steps.cpr.outputs.pull-request-url }}"
|
||||||
git add docs/content/dev/
|
|
||||||
if git diff --staged --quiet; then
|
|
||||||
echo "No changes to commit"
|
|
||||||
else
|
|
||||||
git commit -m "regenerated dev docs from workflow"
|
|
||||||
git push
|
|
||||||
fi
|
|
||||||
- name: Install Node.js dependencies
|
- name: Install Node.js dependencies
|
||||||
run: "cd docs && [[ -f package-lock.json || -f npm-shrinkwrap.json ]] && npm ci || true"
|
run: "cd docs && [[ -f package-lock.json || -f npm-shrinkwrap.json ]] && npm ci || true"
|
||||||
- name: Cache Restore
|
- name: Cache Restore
|
||||||
|
|||||||
Reference in New Issue
Block a user