@@ -13,26 +13,32 @@ jobs:
1313 - name : Free up disk space
1414 run : |
1515 sudo df -h
16- sudo docker system prune -af || true
17- sudo rm -rf /usr/share/dotnet \
18- /usr/local/.ghcup \
19- /usr/local/swift \
20- /usr/share/swift \
21- /usr/lib/jvm \
22- /usr/local/lib/android \
23- /usr/lib/google-cloud-sdk \
24- /usr/local/share/boost \
25- /usr/local/share/powershell \
26- /usr/local/share/chromium \
27- /usr/local/lib/node_modules \
28- /usr/lib/mono \
29- /usr/lib/heroku \
30- /usr/lib/firefox \
31- /usr/share/miniconda \
32- /opt/microsoft \
33- /opt/chrome \
34- /opt/pipx \
35- "$AGENT_TOOLSDIRECTORY" || true
16+ declare -a paths_to_wipe=(
17+ "/usr/share/dotnet"
18+ "/usr/local/.ghcup"
19+ "/usr/local/swift"
20+ "/usr/share/swift"
21+ "/usr/lib/jvm"
22+ "/usr/local/lib/android"
23+ "/usr/lib/google-cloud-sdk"
24+ "/usr/local/share/boost"
25+ "/usr/local/share/powershell"
26+ "/usr/local/share/chromium"
27+ "/usr/local/lib/node_modules"
28+ "/usr/lib/mono"
29+ "/usr/lib/heroku"
30+ "/usr/lib/firefox"
31+ "/usr/share/miniconda"
32+ "/opt/microsoft"
33+ "/opt/chrome"
34+ "/opt/pipx"
35+ "$AGENT_TOOLSDIRECTORY"
36+ )
37+ for p in "${paths_to_wipe[@]}"
38+ do
39+ echo "Clearing $p"
40+ sudo rm -rf $p || true
41+ done
3642 sudo df -h
3743
3844 - uses : actions/checkout@v5
@@ -54,11 +60,42 @@ jobs:
5460 ${{ runner.os }}-gradle-ide-compatibility-
5561
5662 - name : Check compatibility
63+ id : check-compatibility
5764 run : ./gradlew verifyPlugin --info --stacktrace
5865
5966 - name : Upload report
6067 uses : actions/upload-artifact@v4
68+ if : ${{ always() }}
6169 with :
6270 name : plugin-verifier-reports
6371 path : build/reports/pluginVerifier/**
6472 if-no-files-found : warn
73+
74+ - name : Find already existing issue
75+ id : find-issue
76+ if : ${{ always() }}
77+ run : |
78+ echo "number=$(gh issue list -l 'bug' -l 'automated' -L 1 -S 'in:title \"IDE Compatibility Problem\"' -s 'open' --json 'number' --jq '.[].number')" >> $GITHUB_OUTPUT
79+ env :
80+ GH_TOKEN : ${{ github.token }}
81+
82+ - name : Close issue if everything is fine
83+ if : ${{ success() && steps.find-issue.outputs.number != '' }}
84+ run : gh issue close -r 'not planned' ${{ steps.find-issue.outputs.number }}
85+ env :
86+ GH_TOKEN : ${{ github.token }}
87+
88+ - name : Create issue report
89+ if : ${{ failure() && steps.check-compatibility.conclusion == 'failure' }}
90+ run : |
91+ echo 'Encountered problems during plugin verification' > reported.md
92+ echo 'Please check the build logs for details' >> reported.md
93+
94+ - name : Create Issue From File
95+ if : ${{ failure() && steps.check-compatibility.conclusion == 'failure' }}
96+ uses : peter-evans/create-issue-from-file@e8ef132d6df98ed982188e460ebb3b5d4ef3a9cd # v5
97+ with :
98+ issue-number : ${{ steps.find-issue.outputs.number }}
99+ title : IDE Compatibility Problem
100+ content-filepath : ./reported.md
101+ labels : bug, automated
0 commit comments