Skip to content

Commit

Permalink
Merge branch 'feature/ci-cd-pipeline-by-zufar' into feature/test1
Browse files Browse the repository at this point in the history
  • Loading branch information
Sunagatov authored Oct 20, 2023
2 parents a73f93f + 0a56e4a commit 72627e1
Showing 1 changed file with 18 additions and 6 deletions.
24 changes: 18 additions & 6 deletions .github/workflows/ci-cd-pipeline.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,21 @@ jobs:
cache: 'maven'

- name: Build with Maven
run: mvn -B package --file pom.xml

- name: Run unit tests
run: mvn test


run: mvn -B package -Pdev --file pom.xml

# Static code analysis with SonarScanner

- name: Install SonarScanner
run: |
wget https://binaries.sonarsource.com/Distribution/sonar-scanner-cli/sonar-scanner-cli-4.7.0.2747-linux.zip
unzip sonar-scanner-cli-4.7.0.2747-linux.zip
export SONAR_SCANNER_HOME=`pwd`/sonar-scanner-4.7.0.2747-linux
export PATH=$SONAR_SCANNER_HOME/bin:$PATH
- name: Run SonarScanner
run: |
sonar-scanner \
-Dsonar.projectKey=your-project-key \
-Dsonar.sources=. \
-Dsonar.host.url=https://sonarcloud.io \
-Dsonar.login=your-sonarcloud-token

0 comments on commit 72627e1

Please sign in to comment.