Re: assembly plugin - topLevel directory to be supressed in war
Just to provide a workaround.. I punted and ended up using the ant zip task. That works fine. If in the meanwhile someone finds out how to solve this using the assembly plugin please reply to this thread. Thanks Pankaj Pankaj Tandon wrote: Hi, I was away for 10 days so I couldn't participate in this discussion. But thanks Ryan for persuing the cause! However, I'm not sure how the solution is working for you. It will greatly help if you provide details. First, I used the following plugin config: plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-assembly-plugin/artifactId executions execution idassemble/id phaseverify/phase goals goalattached/goal /goals configuration descriptors descriptorsrc/war-assembly.xml/descriptor /descriptors /configuration /execution /executions /plugin Note that in the above config, there is no explicit mention of the version. But when I looked in my local repo, I was getting 2.2-beta-1. So, somehow it *was* pulling the latest version. But anyway, I did mention the version like so: plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-assembly-plugin/artifactId version2.2-beta-1/version executions execution idassemble/id phaseverify/phase goals goalattached/goal /goals configuration descriptors descriptorsrc/war-assembly.xml/descriptor /descriptors /configuration /execution /executions /plugin And just for completeness, here's my descriptor: assembly idportal/id formats formatwar/format /formats includeBaseDirectoryfalse/includeBaseDirectory baseDirectory/baseDirectory fileSets fileSet includes includetarget/portal/**/include outputDirectory//outputDirectory /includes /fileSet /fileSets /assembly I *still* get the target/portal in the top level :( What am I doing wrong? To answer your earlier question, as to why I could not use the war plugin.. it is because the war plugin needs the location of the web.xml in a certain location... herer all I want is the zip up the existing structure after my custom mojo has made mids to it. Any help will be highly appreciated! Thanks Pankaj Ryan Moquin wrote: Yeah, that seems to have solved the problem I must have been stuck then on the 2.1 then. On Dec 27, 2007 3:16 PM, Ryan Moquin [EMAIL PROTECTED] wrote: So, by using that, it pull whatever the latest released version is? On Dec 27, 2007 3:14 PM, Wendy Smoak [EMAIL PROTECTED] wrote: On Dec 27, 2007 1:09 PM, Ryan Moquin [EMAIL PROTECTED] wrote: My pom specified the assembly plugin like this: plugin artifactIdmaven-assembly-plugin/artifactId configuration I'm guessing this means I'm using version 2.2, and more than likely he is using the same thing? It means you're using whatever is in your local repository, so there's no telling. Try adding this... version2.2-beta-1/version -- Wendy - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- View this message in context: http://www.nabble.com/assembly-plugin---topLevel-directory-to-be-supressed-in-war-tp14424240s177p14598572.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: assembly plugin - topLevel directory to be supressed in war
I'm able to generate similar packages without the /target/../ something included using assembly 2.2-beta-1. I don't use baseDirectory tag at all and inside fileset, I use for example: directory${basedir}/target/dependency/directory outputDirectorylib//outputDirectory That works for me. Kalle On 1/3/08, Pankaj Tandon [EMAIL PROTECTED] wrote: Just to provide a workaround.. I punted and ended up using the ant zip task. That works fine. If in the meanwhile someone finds out how to solve this using the assembly plugin please reply to this thread. Thanks Pankaj Pankaj Tandon wrote: Hi, I was away for 10 days so I couldn't participate in this discussion. But thanks Ryan for persuing the cause! However, I'm not sure how the solution is working for you. It will greatly help if you provide details. First, I used the following plugin config: plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-assembly-plugin/artifactId executions execution idassemble/id phaseverify/phase goals goalattached/goal /goals configuration descriptors descriptorsrc/war-assembly.xml/descriptor /descriptors /configuration /execution /executions /plugin Note that in the above config, there is no explicit mention of the version. But when I looked in my local repo, I was getting 2.2-beta-1. So, somehow it *was* pulling the latest version. But anyway, I did mention the version like so: plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-assembly-plugin/artifactId version2.2-beta-1/version executions execution idassemble/id phaseverify/phase goals goalattached/goal /goals configuration descriptors descriptorsrc/war-assembly.xml/descriptor /descriptors /configuration /execution /executions /plugin And just for completeness, here's my descriptor: assembly idportal/id formats formatwar/format /formats includeBaseDirectoryfalse/includeBaseDirectory baseDirectory/baseDirectory fileSets fileSet includes includetarget/portal/**/include outputDirectory//outputDirectory /includes /fileSet /fileSets /assembly I *still* get the target/portal in the top level :( What am I doing wrong? To answer your earlier question, as to why I could not use the war plugin.. it is because the war plugin needs the location of the web.xmlin a certain location... herer all I want is the zip up the existing structure after my custom mojo has made mids to it. Any help will be highly appreciated! Thanks Pankaj Ryan Moquin wrote: Yeah, that seems to have solved the problem I must have been stuck then on the 2.1 then. On Dec 27, 2007 3:16 PM, Ryan Moquin [EMAIL PROTECTED] wrote: So, by using that, it pull whatever the latest released version is? On Dec 27, 2007 3:14 PM, Wendy Smoak [EMAIL PROTECTED] wrote: On Dec 27, 2007 1:09 PM, Ryan Moquin [EMAIL PROTECTED] wrote: My pom specified the assembly plugin like this: plugin artifactIdmaven-assembly-plugin/artifactId configuration I'm guessing this means I'm using version 2.2, and more than likely he is using the same thing? It means you're using whatever is in your local repository, so there's no telling. Try adding this... version2.2-beta-1/version -- Wendy - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- View this message in context: http://www.nabble.com/assembly-plugin---topLevel-directory-to-be-supressed-in-war-tp14424240s177p14598572.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: assembly plugin - topLevel directory to be supressed in war
Hi, I was away for 10 days so I couldn't participate in this discussion. But thanks Ryan for persuing the cause! However, I'm not sure how the solution is working for you. It will greatly help if you provide details. First, I used the following plugin config: plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-assembly-plugin/artifactId executions execution idassemble/id phaseverify/phase goals goalattached/goal /goals configuration descriptors descriptorsrc/war-assembly.xml/descriptor /descriptors /configuration /execution /executions /plugin Note that in the above config, there is no explicit mention of the version. But when I looked in my local repo, I was getting 2.2-beta-1. So, somehow it *was* pulling the latest version. But anyway, I did mention the version like so: plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-assembly-plugin/artifactId version2.2-beta-1/version executions execution idassemble/id phaseverify/phase goals goalattached/goal /goals configuration descriptors descriptorsrc/war-assembly.xml/descriptor /descriptors /configuration /execution /executions /plugin And just for completeness, here's my descriptor: assembly idportal/id formats formatwar/format /formats includeBaseDirectoryfalse/includeBaseDirectory baseDirectory/baseDirectory fileSets fileSet includes includetarget/portal/**/include outputDirectory//outputDirectory /includes /fileSet /fileSets /assembly I *still* get the target/portal in the top level :( What am I doing wrong? To answer your earlier question, as to why I could not use the war plugin.. it is because the war plugin needs the location of the web.xml in a certain location... herer all I want is the zip up the existing structure after my custom mojo has made mids to it. Any help will be highly appreciated! Thanks Pankaj Ryan Moquin wrote: Yeah, that seems to have solved the problem I must have been stuck then on the 2.1 then. On Dec 27, 2007 3:16 PM, Ryan Moquin [EMAIL PROTECTED] wrote: So, by using that, it pull whatever the latest released version is? On Dec 27, 2007 3:14 PM, Wendy Smoak [EMAIL PROTECTED] wrote: On Dec 27, 2007 1:09 PM, Ryan Moquin [EMAIL PROTECTED] wrote: My pom specified the assembly plugin like this: plugin artifactIdmaven-assembly-plugin/artifactId configuration I'm guessing this means I'm using version 2.2, and more than likely he is using the same thing? It means you're using whatever is in your local repository, so there's no telling. Try adding this... version2.2-beta-1/version -- Wendy - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- View this message in context: http://www.nabble.com/assembly-plugin---topLevel-directory-to-be-supressed-in-war-tp14424240s177p14582343.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: assembly plugin - topLevel directory to be supressed in war
I mean I don't think it works to use: includeBaseDirectoryfalse /includeBaseDirectory I just started playing with my assembly descriptors again and don't see to be able to even get the plugin to recognize the baseDirectory tag for some odd reason. On Dec 27, 2007 2:54 PM, Ryan Moquin [EMAIL PROTECTED] wrote: I don't think it works to specify not to include the baseDirectory. I've tried many times and was not able to do this successfully. Is there any reason you aren't letting the war plugin bundle up the war for you? On Dec 19, 2007 3:08 PM, Pankaj Tandon [EMAIL PROTECTED] wrote: Hi, I intend to use the assembly plugin for a very simple task. I need it to war up a folder structure into a WAR file. The folder is already in a WAR format (infact it is an exploded war file) that I modify via a custom mojo and then I'm using the assembly plugin to war it back up again. Sounds simple enough.. but I'm not able to get past the fact that the war'red up file has the baseDirectory as the toplevel folder. My folder structure is as below: portal - jsp1Folder - jsp2Folder - WEB-INF -web.xml -lib -some.jar -anothe.jar -classes someClass.class anotherClass.class Here is my descriptor: assembly idportal/id formats formatwar/format /formats includeBaseDirectoryfalse/includeBaseDirectory baseDirectorytarget/portal/baseDirectory fileSets fileSet includes includetarget/portal/**/include outputDirectory//outputDirectory /includes /fileSet /fileSets /assembly When portal-portal.war is produced via the assembly plugin I get the following structure in the war file that is produced: target - portal - jsp1Folder - jsp2Folder - WEB-INF -web.xml -lib -some.jar -anothe.jar -classes someClass.class anotherClass.class How can I get the war file to look like: - jsp1Folder - jsp2Folder - WEB-INF -web.xml -lib -some.jar -anothe.jar -classes someClass.class anotherClass.class That is without the target/portal in the front of it! Note that I have includeBaseDirectoryfalse/includeBaseDirectory in the descriptor. I even tried different baseDirectories and no baseDirectory. Did not help. I just can't seem to find the correct settings on the descriptor to make this happen. Can someone help? Thanks in advance Pankaj -- View this message in context: http://www.nabble.com/assembly-plugin---topLevel-directory-to-be-supressed-in-war-tp14424240s177p14424240.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: assembly plugin - topLevel directory to be supressed in war
So, by using that, it pull whatever the latest released version is? On Dec 27, 2007 3:14 PM, Wendy Smoak [EMAIL PROTECTED] wrote: On Dec 27, 2007 1:09 PM, Ryan Moquin [EMAIL PROTECTED] wrote: My pom specified the assembly plugin like this: plugin artifactIdmaven-assembly-plugin/artifactId configuration I'm guessing this means I'm using version 2.2, and more than likely he is using the same thing? It means you're using whatever is in your local repository, so there's no telling. Try adding this... version2.2-beta-1/version -- Wendy - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: assembly plugin - topLevel directory to be supressed in war
Yeah, that seems to have solved the problem I must have been stuck then on the 2.1 then. On Dec 27, 2007 3:16 PM, Ryan Moquin [EMAIL PROTECTED] wrote: So, by using that, it pull whatever the latest released version is? On Dec 27, 2007 3:14 PM, Wendy Smoak [EMAIL PROTECTED] wrote: On Dec 27, 2007 1:09 PM, Ryan Moquin [EMAIL PROTECTED] wrote: My pom specified the assembly plugin like this: plugin artifactIdmaven-assembly-plugin/artifactId configuration I'm guessing this means I'm using version 2.2, and more than likely he is using the same thing? It means you're using whatever is in your local repository, so there's no telling. Try adding this... version2.2-beta-1/version -- Wendy - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: assembly plugin - topLevel directory to be supressed in war
My pom specified the assembly plugin like this: plugin artifactIdmaven-assembly-plugin/artifactId configuration I'm guessing this means I'm using version 2.2, and more than likely he is using the same thing? On Dec 27, 2007 3:07 PM, Wendy Smoak [EMAIL PROTECTED] wrote: On Dec 27, 2007 1:03 PM, Ryan Moquin [EMAIL PROTECTED] wrote: He did, it's listed in his example descriptor above. I've never see this work. What version of the assembly plugin are you using? It's in the docs for the latest release, 2.2-beta-1. -- Wendy - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: assembly plugin - topLevel directory to be supressed in war
On Dec 27, 2007 1:03 PM, Ryan Moquin [EMAIL PROTECTED] wrote: He did, it's listed in his example descriptor above. I've never see this work. What version of the assembly plugin are you using? It's in the docs for the latest release, 2.2-beta-1. -- Wendy - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: assembly plugin - topLevel directory to be supressed in war
He did, it's listed in his example descriptor above. I've never see this work. On Dec 27, 2007 2:57 PM, Wendy Smoak [EMAIL PROTECTED] wrote: On Dec 19, 2007 1:08 PM, Pankaj Tandon [EMAIL PROTECTED] wrote: Sounds simple enough.. but I'm not able to get past the fact that the war'red up file has the baseDirectory as the toplevel folder. Have you tried includeBaseDirectoryfalse/includeBaseDirectory ? http://maven.apache.org/plugins/maven-assembly-plugin/assembly.html -- Wendy - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: assembly plugin - topLevel directory to be supressed in war
On Dec 19, 2007 1:08 PM, Pankaj Tandon [EMAIL PROTECTED] wrote: Sounds simple enough.. but I'm not able to get past the fact that the war'red up file has the baseDirectory as the toplevel folder. Have you tried includeBaseDirectoryfalse/includeBaseDirectory ? http://maven.apache.org/plugins/maven-assembly-plugin/assembly.html -- Wendy - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: assembly plugin - topLevel directory to be supressed in war
I don't think it works to specify not to include the baseDirectory. I've tried many times and was not able to do this successfully. Is there any reason you aren't letting the war plugin bundle up the war for you? On Dec 19, 2007 3:08 PM, Pankaj Tandon [EMAIL PROTECTED] wrote: Hi, I intend to use the assembly plugin for a very simple task. I need it to war up a folder structure into a WAR file. The folder is already in a WAR format (infact it is an exploded war file) that I modify via a custom mojo and then I'm using the assembly plugin to war it back up again. Sounds simple enough.. but I'm not able to get past the fact that the war'red up file has the baseDirectory as the toplevel folder. My folder structure is as below: portal - jsp1Folder - jsp2Folder - WEB-INF -web.xml -lib -some.jar -anothe.jar -classes someClass.class anotherClass.class Here is my descriptor: assembly idportal/id formats formatwar/format /formats includeBaseDirectoryfalse/includeBaseDirectory baseDirectorytarget/portal/baseDirectory fileSets fileSet includes includetarget/portal/**/include outputDirectory//outputDirectory /includes /fileSet /fileSets /assembly When portal-portal.war is produced via the assembly plugin I get the following structure in the war file that is produced: target - portal - jsp1Folder - jsp2Folder - WEB-INF -web.xml -lib -some.jar -anothe.jar -classes someClass.class anotherClass.class How can I get the war file to look like: - jsp1Folder - jsp2Folder - WEB-INF -web.xml -lib -some.jar -anothe.jar -classes someClass.class anotherClass.class That is without the target/portal in the front of it! Note that I have includeBaseDirectoryfalse/includeBaseDirectory in the descriptor. I even tried different baseDirectories and no baseDirectory. Did not help. I just can't seem to find the correct settings on the descriptor to make this happen. Can someone help? Thanks in advance Pankaj -- View this message in context: http://www.nabble.com/assembly-plugin---topLevel-directory-to-be-supressed-in-war-tp14424240s177p14424240.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: assembly plugin - topLevel directory to be supressed in war
On Dec 27, 2007 1:09 PM, Ryan Moquin [EMAIL PROTECTED] wrote: My pom specified the assembly plugin like this: plugin artifactIdmaven-assembly-plugin/artifactId configuration I'm guessing this means I'm using version 2.2, and more than likely he is using the same thing? It means you're using whatever is in your local repository, so there's no telling. Try adding this... version2.2-beta-1/version -- Wendy - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
assembly plugin - topLevel directory to be supressed in war
Hi, I intend to use the assembly plugin for a very simple task. I need it to war up a folder structure into a WAR file. The folder is already in a WAR format (infact it is an exploded war file) that I modify via a custom mojo and then I'm using the assembly plugin to war it back up again. Sounds simple enough.. but I'm not able to get past the fact that the war'red up file has the baseDirectory as the toplevel folder. My folder structure is as below: portal - jsp1Folder - jsp2Folder - WEB-INF -web.xml -lib -some.jar -anothe.jar -classes someClass.class anotherClass.class Here is my descriptor: assembly idportal/id formats formatwar/format /formats includeBaseDirectoryfalse/includeBaseDirectory baseDirectorytarget/portal/baseDirectory fileSets fileSet includes includetarget/portal/**/include outputDirectory//outputDirectory /includes /fileSet /fileSets /assembly When portal-portal.war is produced via the assembly plugin I get the following structure in the war file that is produced: target - portal - jsp1Folder - jsp2Folder - WEB-INF -web.xml -lib -some.jar -anothe.jar -classes someClass.class anotherClass.class How can I get the war file to look like: - jsp1Folder - jsp2Folder - WEB-INF -web.xml -lib -some.jar -anothe.jar -classes someClass.class anotherClass.class That is without the target/portal in the front of it! Note that I have includeBaseDirectoryfalse/includeBaseDirectory in the descriptor. I even tried different baseDirectories and no baseDirectory. Did not help. I just can't seem to find the correct settings on the descriptor to make this happen. Can someone help? Thanks in advance Pankaj -- View this message in context: http://www.nabble.com/assembly-plugin---topLevel-directory-to-be-supressed-in-war-tp14424240s177p14424240.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]