Allison, Bob wrote:
I have seen references to the docck plugin floating around the list and
thought I would give it a try to see what it does.  When I tried to
reference it on the command line, I got some strange output [1]. What
surprised me was that it resolved the version to a snapshot and tried to
get it from central.  I checked my local repository and found
maven-metadata-central.xml [2] which explained why Maven resolved the
version.  Is it an error for there to be metadata in central for a
snapshot plugin?


------------------[1]--------------------
[EMAIL PROTECTED] logging]$ mvn docck:check
[INFO] Scanning for projects...
[INFO] Searching repository for plugin with prefix: 'docck'.
[INFO] org.codehaus.mojo: checking for updates from central
[INFO] qaccess.plugins: checking for updates from central
[INFO] org.apache.maven.plugins: checking for updates from central
[INFO] artifact org.apache.maven.plugins:maven-docck-plugin: checking
for updates from central
[INFO]
------------------------------------------------------------------------
[ERROR] BUILD ERROR
[INFO]
------------------------------------------------------------------------
[INFO] Error building POM (may not be this project's POM).


Project ID: org.apache.maven.plugins:maven-docck-plugin

Reason: Error getting POM for
'org.apache.maven.plugins:maven-docck-plugin' from the repository:
Failed to resolve artifact, possibly due to a repository list that is
not appropriately equipped for this artifact's metadata.
  org.apache.maven.plugins:maven-docck-plugin:pom:1.0-SNAPSHOT

from the specified remote repositories:
  central (http://repo1.maven.org/maven2)



[INFO]
------------------------------------------------------------------------
[INFO] For more information, run Maven with the -e switch
[INFO]
------------------------------------------------------------------------
[INFO] Total time: 12 seconds
[INFO] Finished at: Wed Jul 12 06:19:08 EDT 2006
[INFO] Final Memory: 2M/4M
[INFO]
------------------------------------------------------------------------


------------------[2]--------------------
<?xml version="1.0" encoding="UTF-8"?><metadata>
  <groupId>org.apache.maven.plugins</groupId>
  <artifactId>maven-docck-plugin</artifactId>
  <version>1.0-SNAPSHOT</version>
  <versioning>
    <latest>1.0-SNAPSHOT</latest>
    <versions>
      <version>1.0-SNAPSHOT</version>
    </versions>
    <lastUpdated>20060711175747</lastUpdated>
  </versioning>
</metadata>

Here's what I did to make this work.

I put this in my settings.xml file:

  ...
  <profiles>
    <profile>
      <id>apache</id>
      <repositories>
        <repository>
          <id>snapshots</id>
          <url>http://svn.apache.org/maven-snapshot-repository</url>
        </repository>
      </repositories>
      <pluginRepositories>
        <pluginRepository>
          <id>snapshots</id>
          <url>http://svn.apache.org/maven-snapshot-repository</url>
        </pluginRepository>
      </pluginRepositories>
    </profile>
  </profiles>
  ...

And invoke maven like this:

  mvn -Papache docck:check

--
Dennis Lundberg

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to