Julien - When you did this, did you encounter a problem where test dependencies (e.g. Junit) were also copied?
Ken On Tue, Sep 15, 2009 at 2:20 AM, Julien Graglia <[email protected]>wrote: > Le lundi 14 septembre 2009 à 16:17 -0400, James Russo a écrit : > > Hello Julien, > > > > In your ncsetup.nsi, how do you reference the artifacts to be > > included with the .exe build? > My installer artifact is of type pom and depends of my war. Then I use > the assembly plugin to retrieve dependencies and output them in folders. > Ex : > <dependencySets> > <!-- copy all deps in the libs subfolder. target only desps > markes as > "provided" in my war --> > <dependencySet> > <outputDirectory>libs</outputDirectory> > <scope>provided</scope> > <excludes> > <exclude>xxxxxxx:*</exclude> > </excludes> > </dependencySet> > <!-- copy all std deps in the libs subfolder. target only desps markes > as "provided" in my war --> > <dependencySet> > <outputDirectory>libs</outputDirectory> > <excludes> > <exclude>xxxx:*</exclude> > </excludes> > </dependencySet> > <!--retreive all wars --> > <dependencySet> > <outputDirectory>webapps</outputDirectory> > > > <outputFileNameMapping>${artifact.artifactId}.${artifact.extension}</outputFileNameMapping> > <scope>runtime</scope> > <includes> > <!-- > > http://maven.apache.org/plugins/maven-assembly-plugin/advanced-descriptor-topics.html--> > <include>*:war:*</include> > </includes> > </dependencySet> > ... > Then I just have to tell NSIS to include thats folders and install them > > Extract of nsis.script in src/main/nsis/ > SetOutPath "$INSTDIR\libs" > ; copy all jars retrieved from the assembly plugin > File /r ..\..\..\target\xxx-${VERSION}-base\libs\* > SetOutPath "$INSTDIR\webapps" > File /r ..\..\..\target\xxx-${VERSION}-base\webapps\* > > et voilà! > > > > > thanks, > > > > -jr > > > > Julien Graglia wrote: > > > Le lundi 14 septembre 2009 à 10:03 -0400, James Russo a écrit : > > > > > >> Hello, > > >> > > >> I have a module where I would like to take the artifacts producted > > >> by a few other modules and combine them into an .EXE using NSIS. I see > > >> that there is a nsis for maven 1.x, but I don't see anything for 2.x? > > >> Anyone done this before care to explain how they accomplished it? > > >> > > >> Basically would like to have everything I need for NSIS in this module > > >> (other files, readme, configuration, etc) and then have it grab > > >> dependencies from other modules include it in NSIS and generate EXE. > > >> Ultimately I'd like to deploy this .exe to archiva. > > >> > > >> > > > > > > Hi, > > > > > > Funny..., this morning, a guy on the maven irc just told me that a nsis > > > plugin (1) exists for maven 2. > > > today I use : > > > assembly plugin to download dependencies > > > maven exec (2) to run NSIS with some properties during package > phase > > > and build-helper-maven-plugin to attach generated .deb to my > artifact > > > (so that I can donwload the install from archiva (5)) > > > but all these plugins could be replaced by a single call to that nsis > > > plugin. (see extract from my pom in (4)) > > > > > > I will give it a try next week (well I will try to find some time...) > > > > > > > > > 1 : http://mojo.codehaus.org/nsis-maven-plugin/ > > > 2 : http://mojo.codehaus.org/exec-maven-plugin/introduction.html > > > 3 : http://mojo.codehaus.org/build-helper-maven-plugin/howto.html > > > 4 : http://pastie.org/616361 ( but I told you, that nsis plugin could > > > replace the exec+buildhelper part with a single (may be 4:=) ) line(s)) > > > 5: BTW, If you use Archiva, don't forget to add ".exe" extension to the > > > list of artifacts scanned in the repositories) > > > > > > > -- > Julien Graglia > NetCeler > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [email protected] > For additional commands, e-mail: [email protected] > >
