[Users] Migration script: studio 1.0beta2 -> 1.0

gibello pierre-yves.gibello at petalslink.com
Wed Mar 16 10:58:10 CET 2011


See below (script for Unix / Linux shell). Migrates the old project tree into a new one (maven-like) for the new studio.
The pom.xml is missing, but is not required unless you use maven: if so, pick one from a newly generated project, and update it.

Usage:
- Go into your workspace directory
- Launch "migrateToStudioV1.sh <your-su-directory-name>"
(example: "migrateToStudioV1.sh su-FileTransfer-test-provide")

The previous directory is renamed into .old, and the original directory now contains a project migrated to PetalsStudio 1.0 .
Refresh (F5) in PetalsStudio, then "Petals / Fast Export for Petals" to rebuild the SU.

Tested against the FileTransfer, XSLT, EIP and EJB components...

#=========== Script begins here (migrateToStudioV1.sh)
#!/bin/sh
dirname=${1}
dirname=${dirname%/}

if [ ! -f ${dirname}/META-INF/jbi.xml ]
then
 echo "Error: no jbi.xml found"
 exit 1
fi

mv $dirname $dirname.old
mkdir $dirname

cp ${dirname}.old/.project $dirname
echo petals.component.name=`grep petals-[bs] ${dirname}/.project | awk '{print $3}' | sed 's/;//'` > ${dirname}/.petals.properties
mkdir -p ${dirname}/src/main/jbi
mkdir -p ${dirname}/src/main/resources
cp -r ${dirname}.old/META-INF/* ${dirname}/src/main/jbi
cp -r ${dirname}.old/resources/* ${dirname}/src/main/resources 2>/dev/null
cp ${dirname}.old/resources/*wsdl ${dirname}/src/main/jbi 2>/dev/null
rm -f ${dirname}/src/main/resources/*wsdl
cp ${dirname}.old/resources/* ${dirname}/src/main/jbi 2>/dev/null
echo "Migration done."
#================== End of script

------------------------
Pierre-Yves Gibello - PetalsLink




-------------------- m2f --------------------

Subscribe/Unsubscribe emails notifications.

Response to this email will be posted on the Petals forum.
Please delete the existing text before responding :)

Read the topic online:
http://forum.petalslink.com/viewtopic.php?p=30929#30929

-------------------- m2f --------------------


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://forum-list.petalslink.org/pipermail/users/attachments/20110316/03f5ea0c/attachment.htm>


More information about the Users mailing list