Skip to content

Commit

Permalink
fixed workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
rohitmalhotra1420 committed May 15, 2024
1 parent 24fe227 commit f222d66
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion .github/workflows/preview.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ jobs:
runs-on: ubuntu-latest
concurrency: 2

if: github.event.action != 'closed'
steps:
# Check out the repository
- name: Checkout code
Expand All @@ -38,7 +39,7 @@ jobs:
# Comment the deployment URL on the PR
- name: Comment PR with deployment URL
run: |
COMMENT="Preview URL: https://${{ github.repository_owner }}.github.io/${{ github.repository_name }}/pr-preview/${{ github.event.pull_request.number }}"
COMMENT="Preview URL: https://${{ github.repository_owner }}.github.io/${{ github.repository_name }}pr-preview/${{ github.event.pull_request.number }}"
echo "${COMMENT}" > comment.txt
cat comment.txt
curl -d "{\"body\":\"${COMMENT}\"}" -H "Content-Type: application/json" -X POST "${{ github.api_url }}/repos/${{ github.repository }}/issues/${{ github.event.pull_request.number }}/comments" -H "Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}"
Expand Down

0 comments on commit f222d66

Please sign in to comment.