Commit 4889f3e6 authored by Rafael Ostertag's avatar Rafael Ostertag

Added sonar-project.properties. Added `sonar` target to makefile.

parent 28ad1000
...@@ -28,3 +28,5 @@ ...@@ -28,3 +28,5 @@
/dist/ /dist/
.python_virtualenv/ .python_virtualenv/
.virtual_env .virtual_env
/.support_sonar
/.sonar_scanner
PHPDOC ?= support/pear/phpdoc PHPDOC ?= support/pear/phpdoc
JSDOC ?= jsdoc JSDOC ?= jsdoc
SONAR_SCANNER_VERSION = 3.0.3.778
PKG_VERSION = $(shell awk '/version/ { print $$3 }' extension/ext_emconf.php | sed "s/'//g") PKG_VERSION = $(shell awk '/version/ { print $$3 }' extension/ext_emconf.php | sed "s/'//g")
NIGHTLY_DATE = $(shell date '+%Y%m%d') NIGHTLY_DATE = $(shell date '+%Y%m%d')
...@@ -71,7 +73,7 @@ t3sphinx: .virtual_env ...@@ -71,7 +73,7 @@ t3sphinx: .virtual_env
plantuml: plantuml:
cd doc/diagram ; $(MAKE) cd doc/diagram ; $(MAKE)
bootstrap: .phpdocinstall .npmpackages .bowerpackages .plantuml_install .virtual_env bootstrap: .phpdocinstall .npmpackages .bowerpackages .plantuml_install .virtual_env .sonar_scanner
npm update npm update
bower update bower update
grunt default grunt default
...@@ -90,6 +92,13 @@ phpdoc: .phpdocinstall ...@@ -90,6 +92,13 @@ phpdoc: .phpdocinstall
pear -c "`pwd`/support/pear.config" install phpdoc/phpDocumentor pear -c "`pwd`/support/pear.config" install phpdoc/phpDocumentor
touch $@ touch $@
.sonar_scanner: .support_sonar
cd support/sonar ;\
wget https://sonarsource.bintray.com/Distribution/sonar-scanner-cli/sonar-scanner-cli-$(SONAR_SCANNER_VERSION)-linux.zip ;\
unzip -o sonar-scanner-cli-$(SONAR_SCANNER_VERSION)-linux.zip
touch $@
.plantuml_install: .support_plantuml .plantuml_install: .support_plantuml
wget --no-check-certificate -O support/plantuml/plantuml.jar 'https://downloads.sourceforge.net/project/plantuml/plantuml.jar' wget --no-check-certificate -O support/plantuml/plantuml.jar 'https://downloads.sourceforge.net/project/plantuml/plantuml.jar'
touch $@ touch $@
...@@ -113,6 +122,10 @@ phpdoc: .phpdocinstall ...@@ -113,6 +122,10 @@ phpdoc: .phpdocinstall
mkdir -p support/plantuml mkdir -p support/plantuml
touch $@ touch $@
.support_sonar: .support
mkdir -p support/sonar
touch $@
.virtual_env: pip-temp-directory .virtual_env: pip-temp-directory
virtualenv .python_virtualenv virtualenv .python_virtualenv
. .python_virtualenv/bin/activate ; TMPDIR="$(PIP_TMP)" pip install --upgrade sphinx==1.5.5 . .python_virtualenv/bin/activate ; TMPDIR="$(PIP_TMP)" pip install --upgrade sphinx==1.5.5
...@@ -121,4 +134,8 @@ phpdoc: .phpdocinstall ...@@ -121,4 +134,8 @@ phpdoc: .phpdocinstall
pip-temp-directory: pip-temp-directory:
test -d "$(PIP_TMP)" || mkdir -p "$(PIP_TMP)" test -d "$(PIP_TMP)" || mkdir -p "$(PIP_TMP)"
.PHONY: nightly maintainer-clean snapshot release git-revision t3sphinx build-dist make-dist-dir dist-move-doc dist-copy-extension pip-temp-directory plantuml sonar: .sonar_scanner
support/sonar/sonar-scanner-$(SONAR_SCANNER_VERSION)-linux/bin/sonar-scanner
.PHONY: nightly maintainer-clean snapshot release git-revision t3sphinx build-dist make-dist-dir dist-move-doc dist-copy-extension pip-temp-directory plantuml sonar
# must be unique in a given SonarQube instance
sonar.projectKey=qfq
# this is the name and version displayed in the SonarQube UI. Was mandatory prior to SonarQube 6.1.
sonar.projectName=QFQ
sonar.projectVersion=1.0
# Path is relative to the sonar-project.properties file. Replace "\" by "/" on Windows.
# This property is optional if sonar.modules is set.
sonar.sources=.
# Encoding of the source code. Default is default system encoding
#sonar.sourceEncoding=UTF-8
sonar.inclusions = javascript/**/*.js,extension/**/*.php
sonar.exclusions = extension/qfq/tests/**/*.php
sonar.host.url=http://ci.math.uzh.ch:9000
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment