changed scripts to load up the proper jar files and added dist tasks to the gradle build
Project: http://git-wip-us.apache.org/repos/asf/incubator-wave/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-wave/commit/1ffc740c Tree: http://git-wip-us.apache.org/repos/asf/incubator-wave/tree/1ffc740c Diff: http://git-wip-us.apache.org/repos/asf/incubator-wave/diff/1ffc740c Branch: refs/heads/master Commit: 1ffc740cf26c1d0a420140a26844a1af5fa3baf0 Parents: 650d494 Author: wisebaldone <[email protected]> Authored: Fri Dec 4 23:05:06 2015 +1000 Committer: wisebaldone <[email protected]> Committed: Fri Dec 4 23:05:06 2015 +1000 ---------------------------------------------------------------------- wave/build.gradle | 48 +++++++++++++++++++++++++++++++++++- wave/dist/run-data-migration.sh | 4 +-- wave/dist/run-server.bat | 7 +++--- wave/dist/run-server.sh | 11 ++++----- 4 files changed, 57 insertions(+), 13 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/incubator-wave/blob/1ffc740c/wave/build.gradle ---------------------------------------------------------------------- diff --git a/wave/build.gradle b/wave/build.gradle index 0dd7bed..dac7338 100644 --- a/wave/build.gradle +++ b/wave/build.gradle @@ -531,4 +531,50 @@ task createPropertiesFile(type: Copy) { expand([ version: version ]) -} \ No newline at end of file +} + +task createDistZip(type: Zip) { + from(jar) { + into 'apache-wave/bin' + } + from('dist') { + into 'apache-wave' + } + from('config') { + into 'apache-wave/config' + } + from('war') { + into 'apache-wave/war' + } +} + +task createDistTar(type: Tar) { + from(jar) { + into 'apache-wave/bin' + } + from('dist') { + into 'apache-wave' + } + from('config') { + into 'apache-wave/config' + } + from('war') { + into 'apache-wave/war' + } +} + +createDistZip.dependsOn jar, createPropertiesFile +createDistTar.dependsOn jar, createPropertiesFile + +task createDist() { + doFirst { + println '' + println '----------------------------------------------' + println ' Creating Deployment ' + println 'Zip and Tar files available in wave/build/dist' + println '----------------------------------------------' + println '' + } +} + +createDist.dependsOn createDistZip, createDistTar \ No newline at end of file http://git-wip-us.apache.org/repos/asf/incubator-wave/blob/1ffc740c/wave/dist/run-data-migration.sh ---------------------------------------------------------------------- diff --git a/wave/dist/run-data-migration.sh b/wave/dist/run-data-migration.sh index b48eb22..2e8f0ce 100755 --- a/wave/dist/run-data-migration.sh +++ b/wave/dist/run-data-migration.sh @@ -22,7 +22,7 @@ # Run "ant dist-server" before to use this script # The version of Wave in a Box, extracted from the build.properties file -WAVEINABOX_VERSION=`sed "s/[\\t ]*=[\\t ]*/=/g" build.properties | grep ^waveinabox.version= | cut -f2 -d=` +WAVEINABOX_VERSION=`sed "s/[\\t ]*=[\\t ]*/=/g" config/wave.conf | grep ^version= | cut -f2 -d=` echo wave-in-a-box-server-$WAVEINABOX_VERSION.jar -exec java -cp dist/wave-in-a-box-server-$WAVEINABOX_VERSION.jar org.waveprotocol.box.server.DataMigrationTool $* +exec java -cp dist/wave-$WAVEINABOX_VERSION.jar org.waveprotocol.box.server.DataMigrationTool $* http://git-wip-us.apache.org/repos/asf/incubator-wave/blob/1ffc740c/wave/dist/run-server.bat ---------------------------------------------------------------------- diff --git a/wave/dist/run-server.bat b/wave/dist/run-server.bat index f70f6d3..68851ed 100644 --- a/wave/dist/run-server.bat +++ b/wave/dist/run-server.bat @@ -14,11 +14,10 @@ rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. rem See the License for the specific language governing permissions and rem limitations under the License. -for /F "tokens=1* delims==" %%A IN (build.properties) DO ( - IF "%%A"=="waveinabox.version" set WAVEINABOX_VERSION=%%B - IF "%%A"=="name" set NAME=%%B +for /F "tokens=1* delims==" %%A IN (config/wave.conf) DO ( + IF "%%A"=="version" set WAVEINABOX_VERSION=%%B ) echo on -java -Djava.util.logging.config.file=wiab-logging.conf -Djava.security.auth.login.config=jaas.config -Dwave.server.config=server.config -jar dist/%NAME%-server-%WAVEINABOX_VERSION%.jar +java -Djava.util.logging.config.file=config/wiab-logging.conf -Djava.security.auth.login.config=config/jaas.config -Dwave.server.config=config/server.config -jar bin/wave-%WAVEINABOX_VERSION%.jar pause http://git-wip-us.apache.org/repos/asf/incubator-wave/blob/1ffc740c/wave/dist/run-server.sh ---------------------------------------------------------------------- diff --git a/wave/dist/run-server.sh b/wave/dist/run-server.sh index f733bad..5ce538c 100755 --- a/wave/dist/run-server.sh +++ b/wave/dist/run-server.sh @@ -20,13 +20,12 @@ # This script will start the Wave in a Box server. # The version of Wave in a Box, extracted from the build.properties file -WAVEINABOX_VERSION=`sed "s/[\\t ]*=[\\t ]*/=/g" build.properties | grep ^waveinabox.version= | cut -f2 -d=` -NAME=`sed "s/[\\t ]*=[\\t ]*/=/g" build.properties | grep ^name= | cut -f2 -d=` +WAVEINABOX_VERSION=`sed "s/[\\t ]*=[\\t ]*/=/g" config/wave.conf | grep ^version= | cut -f2 -d=` . process-script-args.sh exec java $DEBUG_FLAGS \ - -Djava.util.logging.config.file=wiab-logging.conf \ - -Djava.security.auth.login.config=jaas.config \ - -Dwave.server.config=server.config \ - -jar dist/$NAME-server-$WAVEINABOX_VERSION.jar + -Djava.util.logging.config.file=config/wiab-logging.conf \ + -Djava.security.auth.login.config=config/jaas.config \ + -Dwave.server.config=config/server.config \ + -jar bin/wave-$WAVEINABOX_VERSION.jar
