File tree Expand file tree Collapse file tree 1 file changed +22
-0
lines changed Expand file tree Collapse file tree 1 file changed +22
-0
lines changed Original file line number Diff line number Diff line change 27
27
}' -q .data.repository.issue.id)
28
28
echo "ISSUE_ID=$issue_id" >> $GITHUB_ENV
29
29
30
+ - name : Verify access to project
31
+ env :
32
+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
33
+ DEV_PROJECT_ID : ${{ secrets.DEV_PROJECT_ID }}
34
+ run : |
35
+ result=$(curl -s -H "Authorization: Bearer $GITHUB_TOKEN" \
36
+ -H "Accept: application/vnd.github.v3+json" \
37
+ "https://api.github.com/projects/$DEV_PROJECT_ID")
38
+
39
+ echo "Project response: $result"
40
+
41
+ if echo "$result" | jq -e . >/dev/null 2>&1; then
42
+ project_state=$(echo $result | jq -r '.state')
43
+ if [ "$project_state" != "active" ]; then
44
+ echo "Project is not active or not found"
45
+ exit 1
46
+ fi
47
+ else
48
+ echo "Failed to parse project response as JSON."
49
+ exit 1
50
+ fi
51
+
30
52
- name : Get columns in project
31
53
id : get_columns
32
54
env :
You can’t perform that action at this time.
0 commit comments