Skip to content

Commit

Permalink
Merge branch 'develop' into fixes-PalisadoesFoundation#1772
Browse files Browse the repository at this point in the history
merged latest changes from develop
  • Loading branch information
adi790uu committed Feb 17, 2024
2 parents 9e782a6 + e87e3a6 commit f339c4f
Showing 1 changed file with 32 additions and 18 deletions.
50 changes: 32 additions & 18 deletions .github/workflows/push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -142,31 +142,45 @@ jobs:
git push -f https://[email protected]/PalisadoesFoundation/talawa-api.git HEAD:automated-docs
echo -e "🚀${Green} Hurrah! doc updated${NoColor}"
env:
ACCESS_TOKEN: ${{ secrets.GH_TOKEN }}
ACCESS_TOKEN: ${{secrets.GH_TOKEN}}

- name: Create Documentation Artifact
uses: actions/upload-artifact@v2
with:
name: documentation-api
path: talawa-api-docs

Empty-Commit:
name: Create Empty Commit
runs-on: ubuntu-latest
needs: Generate-Documentation
if: github.ref == 'refs/heads/develop'
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Empty Commit
run: |
git config --global user.name "${{ github.actor }}"
git config --global user.email "${{ github.actor }}@users.noreply.github.com"
git commit --allow-empty -m "Empty commit"
git push origin develop:automated-docs --force
# Copy-docs-to-talawa-docs:
# runs-on: ubuntu-latest
# if: github.ref == 'refs/heads/automated-docs'
# # needs: Generate-Documentation
# steps:
# - uses: actions/checkout@v3
# - uses: dmnemec/[email protected]
# env:
# API_TOKEN_GITHUB: ${{secrets.TALAWA_DOCS_SYNC}}
# with:
# source_file: 'talawa-api-docs/'
# destination_repo: 'PalisadoesFoundation/talawa-docs'
# destination_branch: 'develop'
# destination_folder: 'docs/'
# user_email: '${{env.email}}'
# user_name: '${{github.actor}}'
# commit_message: 'Talawa API docs updated'
Copy-docs-to-talawa-docs:
runs-on: ubuntu-latest
if: github.ref == 'refs/heads/automated-docs' && contains(github.event.head_commit.message, "Empty commit")
steps:
- uses: actions/checkout@v3
- uses: dmnemec/[email protected]
env:
API_TOKEN_GITHUB: ${{secrets.TALAWA_DOCS_SYNC}}
with:
source_file: 'talawa-api-docs/'
destination_repo: 'PalisadoesFoundation/talawa-docs'
destination_branch: 'develop'
destination_folder: 'docs/'
user_email: '${{env.email}}'
user_name: '${{github.actor}}'
commit_message: 'Talawa API docs updated'

# You can find the deployment instructions in the scripts/cloud-api-demo/README.md file
Deploy-Workflow:
Expand Down

0 comments on commit f339c4f

Please sign in to comment.