Re: how to include 'src/main/webapp' in a jar file?

2013-04-08 Thread Aliaksei Lahachou
You may also try maven-assembly-plugin. It may be a little difficult to
configure without experience, but it is very flexible.

Regards,
htfv (Aliaksei Lahachou)


On Wed, Mar 20, 2013 at 1:31 AM, Ron Wheeler rwhee...@artifact-software.com
 wrote:

 You might think about building the jar as a project first and then making
 the war project depend on the jar project.
 This will give you the jar that you want and the war as well.

 Ron


 On 19/03/2013 4:38 PM, Sankaran, Nambi wrote:

 Hi All

 I have a maven web project that has packaging as war. the package
 generates war file that confirms to war format. But, i like to package the
 project as a jar as well along with the default war format. So, I am
 trying to use maven jar plugin to achieve that. I am using the following
 jar plugin configuration.


 plugin
  groupIdorg.apache.maven.**plugins/groupId
  artifactIdmaven-jar-plugin/**artifactId
  executions
  execution
  idmake-a-jar/id
  phasepackage/phase
  goals
  goaljar/goal
  /goals
  /execution
  /executions
  configuration
  classesDirectory${project.**build.outputDirectory}/**
 classesDirectory
  includes
  include../../src/main/**webapp/**/include
  include**/*/include
  /includes
  /configuration
 /plugin

 The package command produces a jar file that contains the classes and
 the contents of 'resources' folder and war file produces a proper 'war'
 file. But the contents of 'src/main/webapp' are not included in the jar
 file. How to include the contents of src/main/webapp in the jar using the
 jar plugin?

 Stack Overflow Question
 http://stackoverflow.com/**questions/15509893/how-to-**
 create-a-war-and-jar-from-a-**web-projecthttp://stackoverflow.com/questions/15509893/how-to-create-a-war-and-jar-from-a-web-project



 --
 Ron Wheeler
 President
 Artifact Software Inc
 email: rwhee...@artifact-software.com
 skype: ronaldmwheeler
 phone: 866-970-2435, ext 102


 --**--**-
 To unsubscribe, e-mail: 
 users-unsubscribe@maven.**apache.orgusers-unsubscr...@maven.apache.org
 For additional commands, e-mail: users-h...@maven.apache.org




Re: how to include 'src/main/webapp' in a jar file?

2013-03-19 Thread Ron Wheeler
You might think about building the jar as a project first and then 
making the war project depend on the jar project.

This will give you the jar that you want and the war as well.

Ron

On 19/03/2013 4:38 PM, Sankaran, Nambi wrote:

Hi All

I have a maven web project that has packaging as war. the package generates war file that confirms to war 
format. But, i like to package the project as a jar as well along with the default war format. 
So, I am trying to use maven jar plugin to achieve that. I am using the following jar plugin configuration.


plugin
 groupIdorg.apache.maven.plugins/groupId
 artifactIdmaven-jar-plugin/artifactId
 executions
 execution
 idmake-a-jar/id
 phasepackage/phase
 goals
 goaljar/goal
 /goals
 /execution
 /executions
 configuration
 
classesDirectory${project.build.outputDirectory}/classesDirectory
 includes
 include../../src/main/webapp/**/include
 include**/*/include
 /includes
 /configuration
/plugin

The package command produces a jar file that contains the classes and the 
contents of 'resources' folder and war file produces a proper 'war' file. But the 
contents of 'src/main/webapp' are not included in the jar file. How to include the 
contents of src/main/webapp in the jar using the jar plugin?

Stack Overflow Question
http://stackoverflow.com/questions/15509893/how-to-create-a-war-and-jar-from-a-web-project




--
Ron Wheeler
President
Artifact Software Inc
email: rwhee...@artifact-software.com
skype: ronaldmwheeler
phone: 866-970-2435, ext 102


-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org