You are viewing a plain text version of this content. The canonical link for it is here.
Posted to npanday-users@incubator.apache.org by Ronan Carty <ro...@gmail.com> on 2012/04/10 10:32:22 UTC
NPanday - Type Zip
Hi,
I am attempting to use NPanday to copy a zip file from a maven repository.
My POM file entry is as follows;
<dependencies>
<dependency>
<groupId>release.product.productname</groupId>
<artifactId>productmanager</artifactId>
<version>1.0</version>
<type>*??????*</type>
</dependency>
</dependencies>
If I was using a dll file, I have found that I can use dotnet-library as
the type and it works fine, but in this case, I have a zip file that I
would like to use.
Is this possible, what value should I use for type? I have tried
<type>zip</type>
<type>dotnet-zip</type>
but neither have worked for me.
thanks,
ronan
Re: NPanday - Type Zip
Posted by Ronan Carty <ro...@gmail.com>.
Hi Bret,
Thanks for the reply, yes it appears npanday is getting the Artifact and
placing it in "..\My Documents\Visual Studio
2010\Projects\NPandayWinForm2\target\productmanager.zip". I would have
assumed it would be placed in the bin folder but I guess the getartifact
with type zip is working for me now.
My problem now is that the build process attempts to open the file for some
reason and the build fails.
[INFO] --- maven-compile-plugin:1.4.0-incubating:compile (default-compile)
@ NPandayWinForm2 ---
[INFO] NPANDAY-066-013: Found Vendor = Vendor = MICROSOFT, Vendor Version =
3.5, Framework Version = 3.5, Executable Paths =
[D:\WINDOWS\Microsoft.NET\Framework\v3.5, D:\Program Files\Microsoft
SDKs\Windows\v7.0A\bin]
[INFO] NPANDAY-068-003: Compiling Artifact: Vendor = MICROSOFT, Language =
MICROSOFT, Assembly Name = D:\Documents and Settings\rcarty\My
Documents\Visual Studio
2010\Projects\NPandayWinForm2\NPandayWinForm2\target\NPandayWinForm2.exe
[INFO] NPANDAY-068-005: Found executable path for csc:
D:\WINDOWS\Microsoft.NET\Framework\v3.5
fatal error CS0009: Metadata file 'd:\Documents and Settings\rcarty\My
Documents\Visual Studio
2010\Projects\NPandayWinForm2\target\productmanager.zip' could not be
opened -- 'File is corrupt.'
On Tue, Apr 10, 2012 at 3:28 PM, Brett Porter <br...@apache.org> wrote:
> 'zip' should work - it will result in the following path:
>
> /release/product/productname/productmanager/1.0/productmanager-1.0.zip
>
> Is that the file you have? If so, what is the error you get?
>
> - Brett
>
> On 10/04/2012, at 8:32 PM, Ronan Carty wrote:
>
> > Hi,
> >
> >
> > I am attempting to use NPanday to copy a zip file from a maven
> repository.
> > My POM file entry is as follows;
> >
> > <dependencies>
> > <dependency>
> > <groupId>release.product.productname</groupId>
> > <artifactId>productmanager</artifactId>
> > <version>1.0</version>
> > <type>*??????*</type>
> > </dependency>
> > </dependencies>
> >
> >
> > If I was using a dll file, I have found that I can use dotnet-library as
> > the type and it works fine, but in this case, I have a zip file that I
> > would like to use.
> >
> > Is this possible, what value should I use for type? I have tried
> >
> > <type>zip</type>
> > <type>dotnet-zip</type>
> >
> > but neither have worked for me.
> >
> >
> >
> > thanks,
> > ronan
>
> --
> Brett Porter
> brett@apache.org
> http://brettporter.wordpress.com/
> http://au.linkedin.com/in/brettporter
> http://twitter.com/brettporter
>
>
>
>
>
>
Re: NPanday - Type Zip
Posted by Brett Porter <br...@apache.org>.
'zip' should work - it will result in the following path:
/release/product/productname/productmanager/1.0/productmanager-1.0.zip
Is that the file you have? If so, what is the error you get?
- Brett
On 10/04/2012, at 8:32 PM, Ronan Carty wrote:
> Hi,
>
>
> I am attempting to use NPanday to copy a zip file from a maven repository.
> My POM file entry is as follows;
>
> <dependencies>
> <dependency>
> <groupId>release.product.productname</groupId>
> <artifactId>productmanager</artifactId>
> <version>1.0</version>
> <type>*??????*</type>
> </dependency>
> </dependencies>
>
>
> If I was using a dll file, I have found that I can use dotnet-library as
> the type and it works fine, but in this case, I have a zip file that I
> would like to use.
>
> Is this possible, what value should I use for type? I have tried
>
> <type>zip</type>
> <type>dotnet-zip</type>
>
> but neither have worked for me.
>
>
>
> thanks,
> ronan
--
Brett Porter
brett@apache.org
http://brettporter.wordpress.com/
http://au.linkedin.com/in/brettporter
http://twitter.com/brettporter
Re: NPanday - Type Zip
Posted by Ronan Carty <ro...@gmail.com>.
Hi,
As a follow up if anyone else has a similar problem, a solution for me
is.....
Adding the following plug-in to the POM.xml located in the visual studio
project folder will allow the maven build to get the file from your
repository and copy it to <outputDirectory> + <destFileName>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<version>2.4</version>
<executions>
<execution>
<id>copy</id>
<phase>process-resources</phase>
<goals>
<goal>copy</goal>
</goals>
<configuration>
<artifactItems>
<artifactItem>
<groupId> release.product.productname </groupId>
<artifactId>propductmanger</artifactId>
<version>1.0</version>
<type>zip</type>
<overWrite>true</overWrite>
<outputDirectory>./lib</outputDirectory>
<destFileName>MYFILE.zip</destFileName>
</artifactItem>
</artifactItems>
<outputDirectory>./lib</outputDirectory>
<overWriteReleases>true</overWriteReleases>
<overWriteSnapshots>true</overWriteSnapshots>
</configuration>
</execution>
</executions>
</plugin>
>
>