Skip to content

Commit

Permalink
ci: use the latest sonarcloud version
Browse files Browse the repository at this point in the history
  • Loading branch information
NachoVazquez committed Nov 28, 2024
1 parent ffd7ef4 commit 5d9348b
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 20 deletions.
7 changes: 3 additions & 4 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,6 @@ jobs:
sonarcloud:
name: SonarCloud
needs: main
runs-on: ubuntu-latest
permissions:
id-token: write
Expand All @@ -114,16 +113,16 @@ jobs:
uses: ./.github/actions/setup
# Uses the cache generated in the distributed step (Needed for the sonar eslint reports).
- name: Lint with reports
run: pnpm exec nx run-many --all --target=lint --configuration=report --parallel=2 --max-warnings=0
run: pnpm exec nx run-many --target=lint --configuration=report --parallel=2 --max-warnings=0
# Uses the cache generated in the distributed step (Needed for the sonar jest coverage reports).
- name: Tests with coverage
run: pnpm exec nx run-many --all --target=test --configuration=coverage --parallel=1 --max-workers=2
run: pnpm exec nx run-many --target=test --configuration=ci --parallel=1 --max-workers=2

- name: Configure Sonar report paths
run: pnpm run configure-sonar-report-paths

- name: SonarCloud Scan
uses: sonarsource/sonarcloud-github-action@v2.1.1
uses: sonarsource/sonarcloud-github-action@v3.1.0
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
6 changes: 2 additions & 4 deletions packages/examples/lumberjack-app/project.json
Original file line number Diff line number Diff line change
Expand Up @@ -83,8 +83,7 @@
"ci": true,
"coverage": true
}
},
"defaultConfiguration": "ci"
}
},
"serve-static": {
"executor": "@nx/web:file-server",
Expand All @@ -102,8 +101,7 @@
"format": "json",
"output-file": "../../../reports/packages/examples/lumberjack-app/lint/report.json"
}
},
"defaultConfiguration": "report"
}
}
}
}
6 changes: 2 additions & 4 deletions packages/internal/console-driver/test-util/project.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,7 @@
"ci": true,
"coverage": true
}
},
"defaultConfiguration": "ci"
}
},
"lint": {
"outputs": ["{workspaceRoot}/reports/packages/internal/console-driver/test-util/lint/report.json"],
Expand All @@ -26,8 +25,7 @@
"format": "json",
"output-file": "../../../../reports/packages/internal/console-driver/test-util/lint/report.json"
}
},
"defaultConfiguration": "report"
}
}
}
}
6 changes: 2 additions & 4 deletions packages/internal/test-util/project.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,7 @@
"ci": true,
"coverage": true
}
},
"defaultConfiguration": "ci"
}
},
"lint": {
"outputs": ["{workspaceRoot}/reports/packages/internal/test-util/lint/report.json"],
Expand All @@ -26,8 +25,7 @@
"format": "json",
"output-file": "../../../reports/packages/internal/test-util/lint/report.json"
}
},
"defaultConfiguration": "report"
}
}
}
}
6 changes: 2 additions & 4 deletions packages/ngworker/lumberjack/project.json
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,7 @@
"ci": true,
"coverage": true
}
},
"defaultConfiguration": "ci"
}
},
"lint": {
"outputs": ["{workspaceRoot}/reports/packages/ngworker/lumberjack/lint/report.json"],
Expand All @@ -73,8 +72,7 @@
"format": "json",
"output-file": "../../../reports/packages/ngworker/lumberjack/lint/report.json"
}
},
"defaultConfiguration": "report"
}
},
"version": {
"dependsOn": ["build"],
Expand Down

0 comments on commit 5d9348b

Please sign in to comment.