Skip to content

Commit

Permalink
Update 99-add-issue-to-project.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
mfranzke authored Dec 11, 2024
1 parent 4ded4e1 commit 2bb7e4a
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions .github/workflows/99-add-issue-to-project.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,15 +33,14 @@ jobs:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
DEV_PROJECT_ID: ${{ secrets.DEV_PROJECT_ID }}
run: |
project_number=$(echo $DEV_PROJECT_ID | jq -r '.split("/")[-1]') # Optional if $DEV_PROJECT_ID is full URL, otherwise remove this line.
columns=$(curl -s -H "Authorization: Bearer $GITHUB_TOKEN" \
-H "Accept: application/vnd.github.inertia-preview+json" \
"https://api.github.com/projects/$project_number/columns")
"https://api.github.com/projects/$DEV_PROJECT_ID/columns")
echo "Columns response: $columns"
if echo "$columns" | jq -e . >/dev/null 2>&1; then
column_id=$(echo $columns | jq -r '.[] | select(.name=="No Status") | .id')
column_id=$(echo $columns | jq -r '.[] | select(.name == "No Status") | .id')
if [ -n "$column_id" ]; then
echo "COLUMN_ID=$column_id" >> $GITHUB_ENV
else
Expand Down

0 comments on commit 2bb7e4a

Please sign in to comment.