Foren

ANT script for building and deploying liferay project

thumbnail
Aritra Ghosh, geändert vor 12 Jahren.

ANT script for building and deploying liferay project

Junior Member Beiträge: 62 Beitrittsdatum: 08.11.11 Neueste Beiträge
Hi All,
I want to automate the our development environment.For this I would like to create an ANT script for building directly portlet projects and deploy it to tomcat server.Can anyone help me out creating the ANT script?
Thank you.

Regards,
Aritra Ghosh
thumbnail
Muniraj saravanan, geändert vor 12 Jahren.

RE: ANT script for building and deploying liferay project

Junior Member Beiträge: 95 Beitrittsdatum: 01.06.11 Neueste Beiträge
build.xml will do this job
thumbnail
Aritra Ghosh, geändert vor 12 Jahren.

RE: ANT script for building and deploying liferay project

Junior Member Beiträge: 62 Beitrittsdatum: 08.11.11 Neueste Beiträge
If you checked out a project fron SVN,it just contains the build.xml as:

<?xml version="1.0"?>
<!DOCTYPE project>
<project name="test-portlet" basedir="." default="deploy">
<import file="../build-common-portlet.xml" />
</project>

But as build-common-portlet.xml does not exist in the project,so if I try to create a war file,it throws error.So,how is it possible to invoke build-common-portlet.xml from the file system?

Thanks & regards,
Aritra
thumbnail
David H Nebinger, geändert vor 12 Jahren.

RE: ANT script for building and deploying liferay project

Liferay Legend Beiträge: 14916 Beitrittsdatum: 02.09.06 Neueste Beiträge
You have to check the project out to the appropriate subtree of the SDK folder, then you have the other scripts. You don't want to try to build outside of the SDK since there can be more going on than simply creating a war file...
thumbnail
Aritra Ghosh, geändert vor 12 Jahren.

RE: ANT script for building and deploying liferay project

Junior Member Beiträge: 62 Beitrittsdatum: 08.11.11 Neueste Beiträge
David H Nebinger:
You have to check the project out to the appropriate subtree of the SDK folder, then you have the other scripts. You don't want to try to build outside of the SDK since there can be more going on than simply creating a war file...


Thanks David for your reply..But I tried that too.I checked-out the portlet project within the portlets file of the plugin-sdk.Now,it is able to find the others dependent xml files from build.xml but still I am getting an error in the project.It's showing no plugin-sdk is configured.Though I added plugin-sdk from windows preferences of eclipse.Any help???

Thanks & regards,
Aritra
thumbnail
David H Nebinger, geändert vor 12 Jahren.

RE: ANT script for building and deploying liferay project

Liferay Legend Beiträge: 14916 Beitrittsdatum: 02.09.06 Neueste Beiträge
That's an issue with Eclipse, not Ant. If you're changing issues, you should probably be changing threads.

Did checking out into the SDK fix the ant build issue?

For the eclipse side, there must be some config item still missing. Are you using a vanilla Eclipse or did you install the Liferay IDE plugins?
thumbnail
Riccardo Ferrari, geändert vor 12 Jahren.

RE: ANT script for building and deploying liferay project

Regular Member Beiträge: 139 Beitrittsdatum: 13.11.10 Neueste Beiträge
Maybe somthing is wrong with your eclipse setup.
Here are some links very usefull to me:

http://www.liferay.com/community/wiki/-/wiki/Main/Liferay+IDE+Installation+Guide
http://www.liferay.com/community/wiki/-/wiki/Main/Liferay+IDE+Getting+Started+Tutorial

Hope it helps
thumbnail
Aritra Ghosh, geändert vor 12 Jahren.

Eclipse issue for building war

Junior Member Beiträge: 62 Beitrittsdatum: 08.11.11 Neueste Beiträge
Ohh sorry David..I just missed to change the thread..I am using latest version of liferay IDE.Checking out the project within the proper subtree of the SDK fixes the ANT problem.But still unable to make war.
Thanks,
Aritra