File tree Expand file tree Collapse file tree
organizations/.github/workflows Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -29,10 +29,10 @@ jobs:
2929 - name : Get the list of repos with GHAS enabled
3030 id : repo_list
3131 run : |
32- repos=$(echo $(./github-foundations-cli list repos --ghas ${{ github.workspace }}/projects))
32+ repos=$(echo $(./github-foundations-cli list repos --ghas ${{ github.workspace }}/projects 2>&1 ))
3333 echo -e "Found repos: $repos"
34- # Default to [] if repos is empty
35- if [ -z "$repos" ]; then
34+ # Default to [] if repos is empty or contains error text
35+ if [ -z "$repos" ] || echo "$repos" | grep -qiE "(not found|panic|error|exception|fatal|fail)" ; then
3636 repos="[]"
3737 else
3838 repos=$(echo -e "${repos}" | sed s/\'/\"/g)
6666 workload_identity_provider : ${{ secrets.WORKLOAD_IDENTITY_PROVIDER }}
6767
6868 - name : For each repo, run the policy checks
69- uses : advanced-security/policy-as-code@v2.9.0
69+ uses : advanced-security/policy-as-code@v2.7.2
7070 # env:
7171 # DEBUG: true
7272 with :
You can’t perform that action at this time.
0 commit comments