aboutsummaryrefslogtreecommitdiffstats
path: root/server/sonar-server/build.gradle
diff options
context:
space:
mode:
authorDavid Rautureau <david.rautureau@sonarsource.com>2018-03-26 18:26:07 +0200
committerSonarTech <sonartech@sonarsource.com>2018-04-10 20:20:54 +0200
commitf7e38afea9986a8663954dffcfcea74a08d608e0 (patch)
tree739f79415c45719c33d958ea674456dabca83596 /server/sonar-server/build.gradle
parent6f01667e7d1262cb7479b393460f66dfa4d8c46a (diff)
downloadsonarqube-f7e38afea9986a8663954dffcfcea74a08d608e0.tar.gz
sonarqube-f7e38afea9986a8663954dffcfcea74a08d608e0.zip
Add sha1 in web.log
Diffstat (limited to 'server/sonar-server/build.gradle')
-rw-r--r--server/sonar-server/build.gradle10
1 files changed, 10 insertions, 0 deletions
diff --git a/server/sonar-server/build.gradle b/server/sonar-server/build.gradle
index c88c09d48b3..7d56f441169 100644
--- a/server/sonar-server/build.gradle
+++ b/server/sonar-server/build.gradle
@@ -12,6 +12,16 @@ sourceSets {
}
}
+
+import org.apache.tools.ant.filters.ReplaceTokens
+processResources {
+ filesMatching('build.properties') {
+ filter ReplaceTokens, tokens: [
+ 'buildNumber': release ? 'git rev-parse HEAD'.execute().text.trim() : 'N/A'
+ ]
+ }
+}
+
dependencies {
// please keep the list grouped by configuration and ordered by name