40 lines
1.3 KiB
Makefile
40 lines
1.3 KiB
Makefile
|
SHELL := /bin/bash
|
||
|
|
||
|
info:
|
||
|
@echo "Achtung: nur auf Entwicklungs- und Testservern einsetzen!"
|
||
|
@echo "make build: build the jar files"
|
||
|
@echo "make psql: start psql shell on the database"
|
||
|
@echo "make resetdata: reset the data in the database"
|
||
|
@echo "make run: run catalina and watch the output"
|
||
|
@echo "make test: run all continuous integration tests"
|
||
|
@echo "make testdomain: run one specific test for domains"
|
||
|
|
||
|
build:
|
||
|
source ~/.profile
|
||
|
cd ~/hsadmin/util && mvn clean install
|
||
|
cd ~/hsadmin/qserv && mvn clean install
|
||
|
cd ~/hsadmin/hsarback && mvn package -DskipTests
|
||
|
cp ~/hsadmin/qserv/target/hsadmin-*.jar ~/tomcatmq/webapps/hsar/WEB-INF/lib/
|
||
|
cp ~/hsadmin/util/target/hsadmin-*.jar ~/tomcatmq/webapps/hsar/WEB-INF/lib/
|
||
|
|
||
|
|
||
|
resetdata:
|
||
|
psql -U tim03_hsatest < ~/hsadmin/hsarback/database/dropschema.sql
|
||
|
psql -U tim03_hsatest < ~/hsadmin/hsarback/database/schema.sql
|
||
|
psql -U tim03_hsatest < ~/hsadmin/hsarback/database/data.sql
|
||
|
|
||
|
test: resetdata
|
||
|
source ~/.profile
|
||
|
cd ~/hsadmin/hsarback && mvn test -Dtest=ContinuousIntegrationTest
|
||
|
|
||
|
testdomain: resetdata
|
||
|
source ~/.profile
|
||
|
cd ~/hsadmin/hsarback && mvn test -Dtest=InitDataTest && mvn test -Dtest=DomainTest
|
||
|
|
||
|
run:
|
||
|
source ~/.profile
|
||
|
cd ~/tomcatmq && ./bin/catalina.sh run
|
||
|
|
||
|
psql:
|
||
|
WHOAMI=`whoami` && psql -U $${WHOAMI//\-/_}
|