Mercurial > dive4elements > river
comparison contrib/make_flys_release/make_release.sh @ 8754:574f8b80799f
Add quotes in Path tests to avoid wrong results if variables are unset
author | Andre Heinecke <andre.heinecke@intevation.de> |
---|---|
date | Fri, 19 Jun 2015 17:42:23 +0200 |
parents | 340111f40f2d |
children | cd8fce40f151 |
comparison
equal
deleted
inserted
replaced
8753:340111f40f2d | 8754:574f8b80799f |
---|---|
158 fi | 158 fi |
159 cd $FLYS_SOURCE_DIR | 159 cd $FLYS_SOURCE_DIR |
160 done | 160 done |
161 | 161 |
162 | 162 |
163 if [ ! -f $FLYS_SOURCE_DIR/OpenLayers-2.11.tar.gz ]; then | 163 if [ ! -f "$FLYS_SOURCE_DIR/OpenLayers-2.11.tar.gz" ]; then |
164 echo "INFO: download OpenLayers-2.11 for client" | 164 echo "INFO: download OpenLayers-2.11 for client" |
165 cd $FLYS_SOURCE_DIR | 165 cd $FLYS_SOURCE_DIR |
166 wget "https://github.com/openlayers/openlayers/releases/download/release-2.11/OpenLayers-2.11.tar.gz" | 166 wget "https://github.com/openlayers/openlayers/releases/download/release-2.11/OpenLayers-2.11.tar.gz" |
167 tar xvfz OpenLayers-2.11.tar.gz | 167 tar xvfz OpenLayers-2.11.tar.gz |
168 # TODO: Remove more superfluous OpenLayers stuff. | 168 # TODO: Remove more superfluous OpenLayers stuff. |
222 | 222 |
223 #Needs to be done before the tomcat replacement below | 223 #Needs to be done before the tomcat replacement below |
224 sed -i -e "s@1a4825f6-925f-11e3-8165-001f29e71d12@${ELBE_MODEL_UUID}@g" \ | 224 sed -i -e "s@1a4825f6-925f-11e3-8165-001f29e71d12@${ELBE_MODEL_UUID}@g" \ |
225 $FLYS_SOURCE_DIR/river/gwt-client/src/main/webapp/images/FLYS_Karte_interactive.html | 225 $FLYS_SOURCE_DIR/river/gwt-client/src/main/webapp/images/FLYS_Karte_interactive.html |
226 | 226 |
227 if [ -d $WEBINF ]; then | 227 if [ -d "$WEBINF" ]; then |
228 echo "INFO: copy custom client configuration to target destination" | 228 echo "INFO: copy custom client configuration to target destination" |
229 WEBINF_DIR=$FLYS_SOURCE_DIR/river/gwt-client/src/main/webapp/WEB-INF/ | 229 WEBINF_DIR=$FLYS_SOURCE_DIR/river/gwt-client/src/main/webapp/WEB-INF/ |
230 cp -R $WEBINF/* $WEBINF_DIR | 230 cp -R $WEBINF/* $WEBINF_DIR |
231 for file in `find $WEBINF_DIR/ -type f`; do | 231 for file in `find $WEBINF_DIR/ -type f`; do |
232 sed -i -e "s@D4E_VERSION@${VERSION}@g" $file | 232 sed -i -e "s@D4E_VERSION@${VERSION}@g" $file |
233 done | 233 done |
234 fi | 234 fi |
235 | 235 |
236 if [ -f $CLIENT_CONF ]; then | 236 if [ -f "$CLIENT_CONF" ]; then |
237 echo "INFO: copy custom java script client configuration to target destination" | 237 echo "INFO: copy custom java script client configuration to target destination" |
238 cp $CLIENT_CONF \ | 238 cp "$CLIENT_CONF" \ |
239 $FLYS_SOURCE_DIR/river/gwt-client/src/main/java/org/dive4elements/river/client/client/config.xml | 239 $FLYS_SOURCE_DIR/river/gwt-client/src/main/java/org/dive4elements/river/client/client/config.xml |
240 fi | 240 fi |
241 | 241 |
242 if [ -n $DGM_PATH ]; then | 242 if [ -n "$DGM_PATH" ]; then |
243 sed -i -e "s@<dgm-path>.*</dgm-path>@<dgm-path>${DGM_PATH}</dgm-path>@g" \ | 243 sed -i -e "s@<dgm-path>.*</dgm-path>@<dgm-path>${DGM_PATH}</dgm-path>@g" \ |
244 $FLYS_SOURCE_DIR/river/artifacts/doc/conf/conf.xml | 244 $FLYS_SOURCE_DIR/river/artifacts/doc/conf/conf.xml |
245 fi | 245 fi |
246 | 246 |
247 if [ -n $WIKI_URL ]; then | 247 if [ -n "$WIKI_URL" ]; then |
248 sed -i -e "s@<help-url>http://example.com</help-url>@<help-url>${WIKI_URL}</help-url>@g" \ | 248 sed -i -e "s@<help-url>http://example.com</help-url>@<help-url>${WIKI_URL}</help-url>@g" \ |
249 $FLYS_SOURCE_DIR/river/artifacts/doc/conf/conf.xml | 249 $FLYS_SOURCE_DIR/river/artifacts/doc/conf/conf.xml |
250 fi | 250 fi |
251 | 251 |
252 if [ -d $SERVER_CONF ]; then | 252 if [ -d "$SERVER_CONF" ]; then |
253 echo "INFO: copy custom server configuration to target destination" | 253 echo "INFO: copy custom server configuration to target destination" |
254 cp -R $SERVER_CONF/* $FLYS_SOURCE_DIR/river/artifacts/doc/conf/ | 254 cp -R $SERVER_CONF/* $FLYS_SOURCE_DIR/river/artifacts/doc/conf/ |
255 for file in `find $FLYS_SOURCE_DIR/river/artifacts/doc/conf -type f`; do | 255 for file in `find $FLYS_SOURCE_DIR/river/artifacts/doc/conf -type f`; do |
256 sed -i -e "s@D4E_VERSION@${VERSION}@g" $file | 256 sed -i -e "s@D4E_VERSION@${VERSION}@g" $file |
257 done | 257 done |
285 flys-$VERSION.tar | 285 flys-$VERSION.tar |
286 mv $FLYS_SOURCE_DIR/river/gwt-client/target/gwt-client-1.0-SNAPSHOT.war \ | 286 mv $FLYS_SOURCE_DIR/river/gwt-client/target/gwt-client-1.0-SNAPSHOT.war \ |
287 flys-${VERSION}.war | 287 flys-${VERSION}.war |
288 tar -rf flys-$VERSION.tar flys-${VERSION}.war | 288 tar -rf flys-$VERSION.tar flys-${VERSION}.war |
289 | 289 |
290 if [ -f $INSTALL ]; then | 290 if [ -f "$INSTALL" ]; then |
291 echo "INFO: prepare custom installation script" | 291 echo "INFO: prepare custom installation script" |
292 cp $INSTALL . | 292 cp $INSTALL . |
293 sed -i "s/D4E_VERSION/$VERSION/g" ./`basename $INSTALL` | 293 sed -i "s/D4E_VERSION/$VERSION/g" ./`basename $INSTALL` |
294 tar -rf flys-$VERSION.tar `basename $INSTALL` | 294 tar -rf flys-$VERSION.tar `basename $INSTALL` |
295 fi | 295 fi |