File tree Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Original file line number Diff line number Diff line change 2323 # List all branches except HEAD and remove origin/ prefix
2424 git fetch --all
2525 branches=$(git branch -r | grep -v '\->' | grep -v HEAD | grep 'origin/sample-code' | sed 's/origin\///')
26- formatted_branches=$(echo $branches | tr '\n' ',' | sed 's/,$//')
27- echo "formatted_branches=$formatted_branches" >> $GITHUB_ENV
26+ formatted_branches=$(echo $branches | jq -R -s -c 'split("\n") | map(select(. != ""))')
27+ echo "branches=$formatted_branches" >> $GITHUB_ENV
28+ echo "::set-output name=branches::$formatted_branches"
29+ echo "Branches: ${{ needs.get-branches.outputs.branches }}"
2830
2931 # Run Maven verify on each branch in parallel
3032 verify-branches :
4042 ref : ${{ matrix.branch }}
4143 fetch-depth : 0
4244
45+ - name : Set up JDK 17
46+ uses : actions/setup-java@v3
47+ with :
48+ java-version : ' 17'
49+ distribution : ' adopt'
50+
4351 - name : Run Maven Verify
4452 run : |
4553 echo "Processing branch: ${{ matrix.branch }}"
You can’t perform that action at this time.
0 commit comments