Skip to content

Commit

Permalink
#2970: autoGen-talawa-admin-docs-debugging
Browse files Browse the repository at this point in the history
  • Loading branch information
bint-Eve committed Jan 6, 2025
1 parent ad123b0 commit 1ba51b5
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions .github/workflows/pull-request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -503,7 +503,7 @@ jobs:
steps:
- uses: actions/checkout@v4
with:
ref: ${{ github.event.pull_request.head.ref }}
ref: ${{ github.event.pull_request.head.sha }}
fetch-depth: 0 # Required for getting full git history
token: ${{ secrets.GITHUB_TOKEN }}

Expand Down Expand Up @@ -579,7 +579,11 @@ jobs:
git status
- name: Check and Commit Documentation
env:
PR_BRANCH: ${{ github.event.pull_request.head.ref }}
PR_REPO: ${{ github.event.pull_request.head.repo.full_name }}
run: |
git remote add fork https://github.com/$PR_REPO.git
# Add all the generated documentation files
git add docs/docs/auto-docs/
git add docs/docs/developer-guide/
Expand All @@ -588,7 +592,7 @@ jobs:
# Commit if there are changes
if [[ -n "$(git status --porcelain)" ]]; then
git commit -m "docs: update auto-generated documentation [skip ci]"
git push origin HEAD: ${{ github.event.pull_request.head.ref }}
git push fork HEAD:$PR_BRANCH
else
echo "No changes to commit"
fi

0 comments on commit 1ba51b5

Please sign in to comment.