bugfix: Fixed the GraphQL query in GitHub Actions workflow to properly use the declared variable for fetching the project item ID.

This commit is contained in:
santiagosayshey
2024-06-28 08:39:59 +09:30
parent 61a363ff93
commit b4522aeefa

View File

@@ -39,14 +39,15 @@ jobs:
}
}
}
}' -f project=$PROJECT_ID -f number=$ISSUE_NUMBER --jq ".data.node.items.nodes[] | select(.content.number == $ISSUE_NUMBER) | .id")
}' -f project=$PROJECT_ID -f number=$ISSUE_NUMBER --jq '.data.node.items.nodes[] | select(.content.number == $number) | .id')
if [ -z "$item_id" ]; then
echo "Error: Project item ID not found for issue number $ISSUE_NUMBER"
exit 1
else:
else
echo "Project item ID found: $item_id"
echo "PROJECT_ITEM_ID=$item_id" >> $GITHUB_ENV
- name: Set status to In Development
env:
GITHUB_TOKEN: ${{ secrets.ADD_TO_PROJECT_PAT }}