From 2852dba419d798926df5d4a504e0c2263259c724 Mon Sep 17 00:00:00 2001 From: Igor Date: Wed, 24 Jul 2024 08:50:04 +0200 Subject: [PATCH 1/3] Add check if config exists --- .../workflows/pull-maintainers-from-database-and-make-a-pr.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/pull-maintainers-from-database-and-make-a-pr.yml b/.github/workflows/pull-maintainers-from-database-and-make-a-pr.yml index 3deebcf7..7c8d2ab1 100644 --- a/.github/workflows/pull-maintainers-from-database-and-make-a-pr.yml +++ b/.github/workflows/pull-maintainers-from-database-and-make-a-pr.yml @@ -61,10 +61,12 @@ jobs: MAINTAINER_GITHUB=$(echo $i | jq --raw-output '.Github' | cut -d"/" -f4) if [[ $BOARD != null && $MAINTAINER_GITHUB != null ]]; then echo "- [$NAME](https://github.com/${MAINTAINER_GITHUB})" + if find config/boards/ -name "${i}.*" -printf 1 -quit | grep -q 1; then for i in $(echo $BOARD | sed "s/,/ /g"); do echo -e " - $i" MAINTAINERS["$i"]+="$MAINTAINER_GITHUB " done + fi fi done From 6ccbf27a487fd2475335b9e28b26f4a2778a45a2 Mon Sep 17 00:00:00 2001 From: Igor Date: Wed, 24 Jul 2024 08:52:54 +0200 Subject: [PATCH 2/3] Update pull-maintainers-from-database-and-make-a-pr.yml --- .../pull-maintainers-from-database-and-make-a-pr.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/pull-maintainers-from-database-and-make-a-pr.yml b/.github/workflows/pull-maintainers-from-database-and-make-a-pr.yml index 7c8d2ab1..47b3336f 100644 --- a/.github/workflows/pull-maintainers-from-database-and-make-a-pr.yml +++ b/.github/workflows/pull-maintainers-from-database-and-make-a-pr.yml @@ -61,12 +61,12 @@ jobs: MAINTAINER_GITHUB=$(echo $i | jq --raw-output '.Github' | cut -d"/" -f4) if [[ $BOARD != null && $MAINTAINER_GITHUB != null ]]; then echo "- [$NAME](https://github.com/${MAINTAINER_GITHUB})" - if find config/boards/ -name "${i}.*" -printf 1 -quit | grep -q 1; then for i in $(echo $BOARD | sed "s/,/ /g"); do - echo -e " - $i" - MAINTAINERS["$i"]+="$MAINTAINER_GITHUB " + if find config/boards/ -name "${i}.*" -printf 1 -quit | grep -q 1; then + echo -e " - $i" + MAINTAINERS["$i"]+="$MAINTAINER_GITHUB " + fi done - fi fi done From 28ee91840f163ca9fd77bab4e1b7bb53b3f27a6b Mon Sep 17 00:00:00 2001 From: Igor Date: Wed, 24 Jul 2024 08:58:22 +0200 Subject: [PATCH 3/3] Update pull-maintainers-from-database-and-make-a-pr.yml --- ...maintainers-from-database-and-make-a-pr.yml | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/.github/workflows/pull-maintainers-from-database-and-make-a-pr.yml b/.github/workflows/pull-maintainers-from-database-and-make-a-pr.yml index 47b3336f..7a2f8430 100644 --- a/.github/workflows/pull-maintainers-from-database-and-make-a-pr.yml +++ b/.github/workflows/pull-maintainers-from-database-and-make-a-pr.yml @@ -78,15 +78,15 @@ jobs: done # rename configuration to .csc where we lost maintainer - grep BOARD_MAINTAINER=\"\" config/boards/*.{wip,conf} | cut -d":" -f1 | - while read -r line; do - if [[ "${line}" != "${line/.conf/.csc}" ]]; then - mv $line ${line/.conf/.csc} - fi - if [[ "${line}" != "${line/.wip/.csc}" ]]; then - mv $line ${line/.wip/.csc} - fi - done + #grep BOARD_MAINTAINER=\"\" config/boards/*.{wip,conf} | cut -d":" -f1 | + # while read -r line; do + # if [[ "${line}" != "${line/.conf/.csc}" ]]; then + # mv $line ${line/.conf/.csc} + # fi + # if [[ "${line}" != "${line/.wip/.csc}" ]]; then + # mv $line ${line/.wip/.csc} + # fi + # done } >> $GITHUB_STEP_SUMMARY