Skip to content

Instantly share code, notes, and snippets.

@ollitapa
Created February 26, 2020 09:50
Show Gist options
  • Save ollitapa/57bbd6911d6a1c421e1f51cf5f653e6b to your computer and use it in GitHub Desktop.
Save ollitapa/57bbd6911d6a1c421e1f51cf5f653e6b to your computer and use it in GitHub Desktop.
Sonar example
sonar.host.url=.....
##########################
# Required configuration #
##########################
# Project key will also be used for binary file
sonar.projectKey=MDNiOS
sonar.projectName=MDNiOS
# Number version (can be found automatically in plist, just comment this line)
#sonar.projectVersion=1.0
# Comment if you have a project with mixed ObjC / Swift
sonar.language=swift
# Project description
sonar.projectDescription=MDNiOS
# Path to source directories
sonar.sources=.
sonar.exclusions=**/*Test/*, **/*Test.swift, Carthage/**/*, CartTool/**/*, MDNiOS.playground/**/*, bitrise.yml
sonar.coverage.exclusions=**/*Test/*, **/*Test.swift, Carthage/**/*, CartTool/**/*, MDNiOS.playground/**/*, bitrise.yml
# Path to test directories (comment if no test)
sonar.tests=.
sonar.test.inclusions=**/*Test.swift
# Paths to exclude from coverage report (surefire, 3rd party libraries etc.)
# sonar.swift.excludedPathsFromCoverage=pattern1,pattern2
sonar.swift.excludedPathsFromCoverage=**/*Test.swift, Carthage/**/*, CartTool/**/*, MDNiOS.playground/**/*
# Xcode project configuration (.xcodeproj)
# and use the later to specify which project(s) to include in the analysis (comma separated list)
# Specify either xcodeproj or xcodeproj + xcworkspace
sonar.swift.project=MDNiOS.xcodeproj
# Specify your appname.
# This will be something like "myApp"
# Use when basename is different from targeted scheme.
# Or when slather fails with 'No product binary found'
sonar.swift.appName=MDNiOS
# Scheme to build your application
sonar.swift.appScheme="MDNiOS Tests"
# Configuration to use for your scheme. if you do not specify that the default will be Debug
sonar.swift.appConfiguration=Debug
##########################
# Optional configuration #
##########################
# Encoding of the source code
sonar.sourceEncoding=UTF-8
# JUnit report generated by run-sonar.sh is stored in sonar-reports/TEST-report.xml
# Change it only if you generate the file on your own
# The XML files have to be prefixed by TEST- otherwise they are not processed
sonar.junit.reportsPath=sonar-reports/TEST-report.xml
# Lizard report generated by run-sonar.sh is stored in sonar-reports/lizard-report.xml
# Change it only if you generate the file on your own
#sonar.swift.lizard.report=sonar-reports/lizard-report.xml
# Cobertura report generated by run-sonar.sh is stored in sonar-reports/coverage-swift.xml
# Change it only if you generate the file on your own
sonar.swift.coverage.reportPattern=sonar-reports/cobertura.xml
# OCLint report generated by run-sonar.sh is stored in sonar-reports/oclint.xml
# Change it only if you generate the file on your own
sonar.swift.swiftlint.report=sonar-reports/swiftlint.txt
# Change it only if you generate the file on your own
# sonar.swift.tailor.report=sonar-reports/*tailor.txt
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment