Skip to content

Commit 74da861

Browse files
authored
Update setup-new-repo.yml
1 parent ff110f7 commit 74da861

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

.github/workflows/setup-new-repo.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ jobs:
6868
if gh api orgs/$OWNER/teams > /dev/null 2>&1; then
6969
if ! gh api orgs/$OWNER/teams/$MAINTAINERS_TEAM > /dev/null 2>&1; then
7070
MAINTAINERS_PARENT_ID=$(gh api orgs/$OWNER/teams/maintainers | jq -r '.id')
71-
MAINTAINERS_PARENT_ID_NUM=$(printf '%d' "$MAINTAINERS_PARENT_ID" 2>/dev/null || echo "")
71+
MAINTAINERS_PARENT_ID_NUM=$(echo "$MAINTAINERS_PARENT_ID" | grep -o '[0-9]*')
7272
if [ -z "$MAINTAINERS_PARENT_ID_NUM" ]; then
7373
echo "::error::Invalid team ID format for maintainers. Expected numeric ID."
7474
exit 1
@@ -80,7 +80,7 @@ jobs:
8080
8181
if ! gh api orgs/$OWNER/teams/$CODEOWNERS_TEAM > /dev/null 2>&1; then
8282
CODEOWNERS_PARENT_ID=$(gh api orgs/$OWNER/teams/codeowners | jq -r '.id')
83-
CODEOWNERS_PARENT_ID_NUM=$(printf '%d' "$CODEOWNERS_PARENT_ID" 2>/dev/null || echo "")
83+
CODEOWNERS_PARENT_ID_NUM=$(echo "$CODEOWNERS_PARENT_ID" | grep -o '[0-9]*')
8484
if [ -z "$CODEOWNERS_PARENT_ID_NUM" ]; then
8585
echo "::error::Invalid team ID format for codeowners. Expected numeric ID."
8686
exit 1

0 commit comments

Comments
 (0)