-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdeploy.sh
More file actions
executable file
·64 lines (55 loc) · 2.8 KB
/
Copy pathdeploy.sh
File metadata and controls
executable file
·64 lines (55 loc) · 2.8 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
#!/bin/bash
#-----------------------------------------------------------------------------------------------
# Updates the eclipse development environment and deploys the ws artifact
# to the Brisskit maven repository.
#
#
# Notes:
# (1) Maven 2 must be installed
# (2) Your maven settings.xml file should be set up to point to the brisskit maven repo.
# (3) You must have authority to deploy, which depends upon having an account on the machine
# hosting the maven repository.
#
# Author: Jeff Lusted (jl99@leicester.ac.uk)
#-----------------------------------------------------------------------------------------------
#===========================================================================
# Cleaning the lib directory...
#===========================================================================
rm -Rf ./WebContent/WEB-INF/lib/*
#===========================================================================
# Changing the pom packaging to 'war'...
#===========================================================================
mv ./pom.xml ./pom.xml.bak
sed s:\<packaging\>pom\<\/packaging\>:\<packaging\>war\<\/packaging\>: <./pom.xml.bak >./pom.xml
#===========================================================================
# Clean the output directories, setup the classpath and the classes...
#===========================================================================
mvn clean eclipse:eclipse compile
#===========================================================================
# Changing the pom packaging back to 'pom'...
#===========================================================================
mv ./pom.xml ./pom.xml.bak
sed s:\<packaging\>war\<\/packaging\>:\<packaging\>pom\<\/packaging\>: <./pom.xml.bak >./pom.xml
#===========================================================================
# Do a build and deploy into the maven repo
#===========================================================================
mvn deploy
#===================================================================================
# Ensure the war's lib directory contents is available to the local environment...
#===================================================================================
mkdir ./target/tmp
mkdir ./WebContent/WEB-INF/lib >/dev/null 2>/dev/null
mv ./target/i2b2WS.war ./target/tmp
cd ./target/tmp/
unzip i2b2WS.war >/dev/null 2>/dev/null
cd ../..
cp ./target/tmp/WEB-INF/lib/* ./WebContent/WEB-INF/lib
#===========================================================================
# Tidy up...
#===========================================================================
rm ./pom.xml.bak
rm -Rf ./target/tmp
echo ""
echo "!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!"
echo " Please refresh your Eclipse environment. "
echo "!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!"