mirror of
https://github.com/SonarSource/sonarqube.git
synced 2024-08-31 05:55:40 +02:00
45 lines
1.2 KiB
Groovy
45 lines
1.2 KiB
Groovy
sonarqube {
|
|
properties {
|
|
property "sonar.projectName", "${projectTitle} :: VSTS"
|
|
property "sonar.sources", "src/main/js"
|
|
property "sonar.tests", "src/main/js"
|
|
property "sonar.test.inclusions", "src/main/js/**/__tests__/**"
|
|
property "sonar.exclusions", "src/main/js/libs/third-party/**/*,src/main/js/**/__tests__/**"
|
|
}
|
|
}
|
|
|
|
apply plugin: 'com.moowork.node'
|
|
|
|
node {
|
|
version = '8.10.0'
|
|
yarnVersion = '1.5.1'
|
|
download = true
|
|
}
|
|
|
|
yarn_run {
|
|
['config', 'public', 'scripts', 'src'].each {
|
|
inputs.dir(it).withPathSensitivity(PathSensitivity.RELATIVE)
|
|
}
|
|
['.babelrc', 'package.json', 'tsconfig.json', 'yarn.lock'].each {
|
|
inputs.file(it).withPathSensitivity(PathSensitivity.RELATIVE)
|
|
}
|
|
outputs.dir('build/webapp')
|
|
outputs.cacheIf { true }
|
|
|
|
args = ['build']
|
|
}
|
|
|
|
yarn_run.dependsOn ':server:sonar-web:yarn_run'
|
|
|
|
def sources = fileTree(dir: "src") + fileTree(dir: "scripts") + fileTree(dir: "config")
|
|
|
|
task licenseCheckWeb(type: com.hierynomus.gradle.license.tasks.LicenseCheck) {
|
|
source = sources
|
|
}
|
|
licenseMain.dependsOn licenseCheckWeb
|
|
|
|
task licenseFormatWeb(type: com.hierynomus.gradle.license.tasks.LicenseFormat) {
|
|
source = sources
|
|
}
|
|
licenseFormat.dependsOn licenseFormatWeb
|