Skip to content

Update pre-rejected.yml #6

Update pre-rejected.yml

Update pre-rejected.yml #6

Workflow file for this run

name: Move related JIRA tasks status from CODE REVIEW to IN PROGRESS
on:
# pull_request_review:
# types: [submitted]
jobs:
update-jira:
if: github.event.review.state == 'changes_requested' || github.event.review.state == 'dismissed'
runs-on: ubuntu-latest
steps:
#- name: Move related JIRA tasks status from CODE REVIEW to IN PROGRESS
# run: |
# temp=$(echo "${{ github.event.pull_request.title }}" | grep -o '\[[^]]*\]' | sed 's/\[//;s/\]//' | tr -d ' ')
# IFS=$',' read -ra keys <<< "$temp"
# for key in "${keys[@]}"; do
# echo "Move $key to IN PROGRESS."
# curl -u ${{ secrets.JIRA_USER_EMAIL }}:${{ secrets.JIRA_API_TOKEN }} -X POST --data '{"transition":{"id":"21"}}' -H "Content-Type: application/json" ${{ secrets.JIRA_BASE_URL }}/rest/api/3/issue/$key/transitions
# done