Skip to content

Commit fd194d6

Browse files
authored
Merge pull request espressif#145 from adafruit/warn-if-no-arduino-library
throw warnings if action_install.sh is used and repo does not have 'arduino-library' tag in its topic
2 parents 60471ff + 2656527 commit fd194d6

File tree

2 files changed

+11
-2
lines changed

2 files changed

+11
-2
lines changed

.github/workflows/githubci.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@ jobs:
88
runs-on: ubuntu-latest
99

1010
steps:
11-
- uses: actions/checkout@v1
12-
- uses: actions/setup-python@v1
11+
- uses: actions/checkout@v3
12+
- uses: actions/setup-python@v4
1313
with:
1414
python-version: '3.x'
1515
- name: pre-install

actions_install.sh

+9
Original file line numberDiff line numberDiff line change
@@ -32,3 +32,12 @@ echo $GITHUB_WORKSPACE/bin >> $GITHUB_PATH
3232
curl -fsSL https://raw.githubusercontent.com/arduino/arduino-cli/master/install.sh | sh
3333
arduino-cli config init > /dev/null
3434
arduino-cli core update-index > /dev/null
35+
36+
# warn if this library does not have arduino-library tag in its topic
37+
if [ $GITHUB_REPOSITORY != "adafruit/ci-arduino" ]; then
38+
repo_topics=$(curl --request GET --url "https://api.github.com/repos/$GITHUB_REPOSITORY" | jq -r '.topics[]' | xargs)
39+
if [[ ! $repo_topics =~ "arduino-library" ]]; then
40+
echo "::warning::arduino-library is not found in this repo topics. Please add this tag in repo About"
41+
fi
42+
fi
43+

0 commit comments

Comments
 (0)