Skip to content

Commit

Permalink
add code review function
Browse files Browse the repository at this point in the history
  • Loading branch information
Krusty93 committed Jan 10, 2024
1 parent 4623f3f commit 5a51df4
Showing 1 changed file with 45 additions and 0 deletions.
45 changes: 45 additions & 0 deletions .github/workflows/code_review_functions.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
name: Code Review onboarding-functions

on:
pull_request:
branches:
- main
- develop
types:
- opened
- synchronize
- reopened
paths:
- 'apps/onboarding-functions/**'

workflow_dispatch:

jobs:

code-review:
runs-on: ubuntu-latest
permissions:
packages: read
id-token: write
steps:
- name: Setup Maven Action
uses: s4u/setup-maven-action@fa2c7e4517ed008b1f73e7e0195a9eecf5582cd4 # [email protected]
with:
checkout-fetch-depth: 0
java-version: 17
java-distribution: 'temurin'
maven-version: '3.9.5'
cache-enabled: true

- name: Build and analyze on Pull Requests
shell: bash
run: mvn --projects :test-coverage --also-make verify -Ponboarding-functions,report,coverage
-Dsonar.organization=pagopa
-Dsonar.projectKey=pagopa_selfcare-onboarding
-Dsonar.token=${{ secrets.SONAR_TOKEN }}
-Dsonar.pullrequest.key=${{ github.event.pull_request.number }}
-Dsonar.pullrequest.branch=${{ github.head_ref }}
-Dsonar.pullrequest.base=refs/remotes/origin/${{ github.base_ref }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}

0 comments on commit 5a51df4

Please sign in to comment.