maven-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Cody Zhang <codyzhang.w...@gmail.com>
Subject Re: maven plugin develop get repository value from setting.xml
Date Fri, 19 Nov 2010 08:47:43 GMT
it'work! [?]
1.add dependency in pom.xml
  <dependency>
<groupId>org.apache.maven</groupId>
<artifactId>maven-settings</artifactId>
<version>${mavenVersion}</version>
</dependency>

2. private MavenProject project;

/**
 * @parameter expression="${settings}"
 * @required
 * @since 1.0
 * @readonly
 */
so,get & set

3.String localRepository = settings.getLocalRepository();


    Best Regards,
        --Cody.Zhang


在 2010年11月19日 下午4:05,Cody Zhang <codyzhang.work@gmail.com>写道:

> Hi,All
>     I develop maven plugin for our app! How to  get repository value from
> setting.xml .
>
> <localRepository>e:/workspace/user/.m2/repository</localRepository>
>
>     Best Regards,
>         --Cody.Zhang
>

Mime
  • Unnamed multipart/related (inline, None, 0 bytes)
View raw message