Skip to content

Commit

Permalink
Update push.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
tasneemkoushar authored Feb 11, 2024
1 parent 73b68f0 commit 4e6113d
Showing 1 changed file with 2 additions and 23 deletions.
25 changes: 2 additions & 23 deletions .github/workflows/push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ jobs:
git config --global user.email "${{env.email}}"
git add .
git commit -m "Update documentation"
git push -f https://$GH_TOKEN@github.com/PalisadoesFoundation/talawa-api.git HEAD:develop
git push -f https://$GH_TOKEN@github.com/PalisadoesFoundation/talawa-api.git HEAD:automated-docs
echo -e "🚀${Green} Hurrah! doc updated${NoColor}"
env:
ACCESS_TOKEN: ${{ secrets.GH_TOKEN }}
Expand All @@ -153,7 +153,7 @@ jobs:
Copy-docs-to-talawa-docs:
runs-on: ubuntu-latest
if: github.ref == 'refs/heads/automated-docs'
needs: Generate-Documentation
# needs: Generate-Documentation
steps:
- uses: actions/checkout@v3
- uses: dmnemec/copy_file_to_another_repo_action@v1.1.1
Expand All @@ -167,28 +167,7 @@ jobs:
user_email: '${{env.email}}'
user_name: '${{github.actor}}'
commit_message: 'Talawa API docs updated'

name: Pull Changes on Push to Develop Branch

pull_changes:
if: github.ref == 'refs/heads/develop' && github.event_name == 'push'
runs-on: ubuntu-latest
needs: Generate-Documentation
steps:
- name: Checkout code
uses: actions/checkout@v2
with:
ref: develop

- name: Pull changes from develop branch
run: git pull origin develop

- name: Push changes to automated-docs branch
run: |
git config --global user.email "actions@github.com"
git config --global user.name "GitHub Actions"
git push origin HEAD:automated-docs
# You can find the deployment instructions in the scripts/cloud-api-demo/README.md file
Deploy-Workflow:
name: Deploying Application to Cloud VPS
Expand Down

0 comments on commit 4e6113d

Please sign in to comment.