You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by jd...@apache.org on 2005/07/14 22:35:25 UTC

svn commit: r219089 - in /maven/components/trunk: ./ maven-core-it-verifier/src/main/java/org/apache/maven/it/ maven-core/src/main/java/org/apache/maven/cli/ maven-core/src/main/java/org/apache/maven/plugin/version/ maven-plugin-registry/ maven-setting...

Author: jdcasey
Date: Thu Jul 14 13:35:23 2005
New Revision: 219089

URL: http://svn.apache.org/viewcvs?rev=219089&view=rev
Log:
Cleaned up plugin-version resolution.

o Added four command-line options:

  --check-plugin-updates is a synonym for --update-plugins
  
  --no-plugin-registry turns off usage of plugin-registry.xml for plugin version resolution for the current build.
  
  --check-plugin-latest turns on usage of LATEST metadata for plugin version resolution for the current build.

  --no-plugin-latest turns off usage of LATEST metadata for plugin version resolution for the current build.

o Added settings.xml configuration <usePluginRegistry>true|false</usePluginRegistry> to en/disable the use of plugin-registry.xml for plugin version resolution. The default value is true, to use the plugin-registry.xml.

o Added plugin-registry.xml configuration <checkLatest>true|false</checkLatest> to en/disable the use of LATEST metadata when resolving plugin versions. The default value is false, or do not use LATEST.


Modified:
    maven/components/trunk/m2-bootstrap-all.bat
    maven/components/trunk/m2-bootstrap-all.sh
    maven/components/trunk/maven-core-it-verifier/src/main/java/org/apache/maven/it/Verifier.java
    maven/components/trunk/maven-core/src/main/java/org/apache/maven/cli/MavenCli.java
    maven/components/trunk/maven-core/src/main/java/org/apache/maven/plugin/version/DefaultPluginVersionManager.java
    maven/components/trunk/maven-plugin-registry/plugin-registry.mdo
    maven/components/trunk/maven-settings/settings.mdo
    maven/components/trunk/maven-settings/src/main/java/org/apache/maven/settings/RuntimeInfo.java

Modified: maven/components/trunk/m2-bootstrap-all.bat
URL: http://svn.apache.org/viewcvs/maven/components/trunk/m2-bootstrap-all.bat?rev=219089&r1=219088&r2=219089&view=diff
==============================================================================
--- maven/components/trunk/m2-bootstrap-all.bat (original)
+++ maven/components/trunk/m2-bootstrap-all.bat Thu Jul 14 13:35:23 2005
@@ -122,7 +122,7 @@
 echo -----------------------------------------------------------------------
 cd maven-plugins
 @REM update the release info to ensure these versions get used in the integration tests
-call m2 --no-plugin-updates --batch-mode -DupdateReleaseInfo=true -e %MAVEN_CMD_LINE_ARGS% clean:clean install
+call m2 --no-plugin-registry --check-plugin-latest --batch-mode -DupdateReleaseInfo=true -e %MAVEN_CMD_LINE_ARGS% clean:clean install
 cd ..
 
 echo
@@ -131,7 +131,7 @@
 echo -----------------------------------------------------------------------
 cd maven-reports
 @REM update the release info to ensure these versions get used in the integration tests
-call m2 --no-plugin-updates --batch-mode -DupdateReleaseInfo=true -e %MAVEN_CMD_LINE_ARGS% clean:clean install
+call m2 --no-plugin-registry --check-plugin-latest --batch-mode -DupdateReleaseInfo=true -e %MAVEN_CMD_LINE_ARGS% clean:clean install
 cd ..
 
 echo

Modified: maven/components/trunk/m2-bootstrap-all.sh
URL: http://svn.apache.org/viewcvs/maven/components/trunk/m2-bootstrap-all.sh?rev=219089&r1=219088&r2=219089&view=diff
==============================================================================
--- maven/components/trunk/m2-bootstrap-all.sh (original)
+++ maven/components/trunk/m2-bootstrap-all.sh Thu Jul 14 13:35:23 2005
@@ -57,7 +57,7 @@
 
   cd maven-plugins
   # update the release info to ensure these versions get used in the integration tests
-  m2 --no-plugin-updates --batch-mode -DupdateReleaseInfo=true -e $ARGS clean:clean install
+  m2 --no-plugin-registry --check-plugin-latest --batch-mode -DupdateReleaseInfo=true -e $ARGS clean:clean install
   ret=$?; if [ $ret != 0 ]; then exit $ret; fi
 )
 ret=$?; if [ $ret != 0 ]; then exit $ret; fi
@@ -69,7 +69,7 @@
 
   cd maven-reports
   # update the release info to ensure these versions get used in the integration tests
-  m2 --no-plugin-updates --batch-mode -DupdateReleaseInfo=true -e $ARGS clean:clean install
+  m2 --no-plugin-registry --check-plugin-latest --batch-mode -DupdateReleaseInfo=true -e $ARGS clean:clean install
   ret=$?; if [ $ret != 0 ]; then exit $ret; fi
 )
 ret=$?; if [ $ret != 0 ]; then exit $ret; fi
@@ -79,7 +79,7 @@
   echo
   echo "Running maven-core integration tests ..."
   echo 
-  ./maven-core-it.sh --batch-mode "$HOME_ARGS" $ARGS
+  ./maven-core-it.sh "$HOME_ARGS" $ARGS
   ret=$?; if [ $ret != 0 ]; then exit $ret; fi
 )
 ret=$?; if [ $ret != 0 ]; then exit $ret; fi

Modified: maven/components/trunk/maven-core-it-verifier/src/main/java/org/apache/maven/it/Verifier.java
URL: http://svn.apache.org/viewcvs/maven/components/trunk/maven-core-it-verifier/src/main/java/org/apache/maven/it/Verifier.java?rev=219089&r1=219088&r2=219089&view=diff
==============================================================================
--- maven/components/trunk/maven-core-it-verifier/src/main/java/org/apache/maven/it/Verifier.java (original)
+++ maven/components/trunk/maven-core-it-verifier/src/main/java/org/apache/maven/it/Verifier.java Thu Jul 14 13:35:23 2005
@@ -493,9 +493,12 @@
 
             cli.setExecutable( executable );
             
-            cli.createArgument().setValue( "-e" );
+//            cli.createArgument().setValue( "-e" );
+            cli.createArgument().setValue( "-X" );
             
-            cli.createArgument().setValue( "--no-plugin-updates" );
+            cli.createArgument().setValue( "--no-plugin-registry" );
+            
+            cli.createArgument().setValue( "--check-plugin-latest" );
             
             cli.createArgument().setValue( "--batch-mode" );
 

Modified: maven/components/trunk/maven-core/src/main/java/org/apache/maven/cli/MavenCli.java
URL: http://svn.apache.org/viewcvs/maven/components/trunk/maven-core/src/main/java/org/apache/maven/cli/MavenCli.java?rev=219089&r1=219088&r2=219089&view=diff
==============================================================================
--- maven/components/trunk/maven-core/src/main/java/org/apache/maven/cli/MavenCli.java (original)
+++ maven/components/trunk/maven-core/src/main/java/org/apache/maven/cli/MavenCli.java Thu Jul 14 13:35:23 2005
@@ -192,7 +192,8 @@
             settings.setInteractiveMode( false );
         }
 
-        if ( commandLine.hasOption( CLIManager.FORCE_PLUGIN_UPDATES ) )
+        if ( commandLine.hasOption( CLIManager.FORCE_PLUGIN_UPDATES )
+            || commandLine.hasOption( CLIManager.FORCE_PLUGIN_UPDATES2 ) )
         {
             settings.getRuntimeInfo().setPluginUpdateOverride( Boolean.TRUE );
         }
@@ -200,6 +201,20 @@
         {
             settings.getRuntimeInfo().setPluginUpdateOverride( Boolean.FALSE );
         }
+        
+        if ( commandLine.hasOption( CLIManager.FORCE_PLUGIN_LATEST_CHECK ) )
+        {
+            settings.getRuntimeInfo().setCheckLatestPluginVersion( Boolean.TRUE );
+        }
+        else if ( commandLine.hasOption( CLIManager.SUPPRESS_PLUGIN_LATEST_CHECK ) )
+        {
+            settings.getRuntimeInfo().setCheckLatestPluginVersion( Boolean.FALSE );
+        }
+        
+        if ( commandLine.hasOption( CLIManager.SUPPRESS_PLUGIN_REGISTRY ) )
+        {
+            settings.setUsePluginRegistry( false );
+        }
 
         List projectFiles = null;
         try
@@ -508,9 +523,17 @@
 
         public static final char ACTIVATE_PROFILES = 'P';
 
-        public static final String FORCE_PLUGIN_UPDATES = "update-plugins";
+        public static final String FORCE_PLUGIN_UPDATES = "check-plugin-updates";
 
+        public static final String FORCE_PLUGIN_UPDATES2 = "update-plugins";
+        
         public static final String SUPPRESS_PLUGIN_UPDATES = "no-plugin-updates";
+        
+        public static final String SUPPRESS_PLUGIN_REGISTRY = "no-plugin-registry";
+        
+        public static final String FORCE_PLUGIN_LATEST_CHECK = "check-plugin-latest";
+        
+        public static final String SUPPRESS_PLUGIN_LATEST_CHECK = "no-plugin-latest";
 
         public static final char CHECKSUM_FAILURE_POLICY = 'C';
 
@@ -541,9 +564,17 @@
                 "Update all snapshots regardless of repository policies" ).create( UPDATE_SNAPSHOTS ) );
             options.addOption( OptionBuilder.withLongOpt( "activate-profiles" ).withDescription(
                 "Comma-delimited list of profiles to activate").hasArg().create( ACTIVATE_PROFILES ) );
+            
             options.addOption( OptionBuilder.withLongOpt( "batch-mode" ).withDescription( "Run in non-interactive (batch) mode" ).create( BATCH_MODE ) );
+            
             options.addOption( OptionBuilder.withLongOpt( FORCE_PLUGIN_UPDATES ).withDescription( "Force upToDate check for any relevant registered plugins" ).create() );
+            options.addOption( OptionBuilder.withLongOpt( FORCE_PLUGIN_UPDATES2 ).withDescription( "Synonym for " + FORCE_PLUGIN_UPDATES ).create() );
             options.addOption( OptionBuilder.withLongOpt( SUPPRESS_PLUGIN_UPDATES ).withDescription( "Suppress upToDate check for any relevant registered plugins" ).create() );
+            options.addOption( OptionBuilder.withLongOpt( FORCE_PLUGIN_LATEST_CHECK ).withDescription( "Force checking of LATEST metadata for plugin versions" ).create() );
+            options.addOption( OptionBuilder.withLongOpt( SUPPRESS_PLUGIN_LATEST_CHECK ).withDescription( "Suppress checking of LATEST metadata for plugin versions" ).create() );
+            
+            options.addOption( OptionBuilder.withLongOpt( SUPPRESS_PLUGIN_REGISTRY ).withDescription( "Don't use ~/.m2/plugin-registry.xml for plugin versions" ).create() );
+            
             options.addOption( OptionBuilder.withLongOpt( "strict-checksums" ).withDescription( "Fail the build if checksums don't match" ).create( CHECKSUM_FAILURE_POLICY ) );
             options.addOption( OptionBuilder.withLongOpt( "lax-checksums" ).withDescription( "Warn if checksums don't match" ).create( CHECKSUM_WARNING_POLICY ) );
         }

Modified: maven/components/trunk/maven-core/src/main/java/org/apache/maven/plugin/version/DefaultPluginVersionManager.java
URL: http://svn.apache.org/viewcvs/maven/components/trunk/maven-core/src/main/java/org/apache/maven/plugin/version/DefaultPluginVersionManager.java?rev=219089&r1=219088&r2=219089&view=diff
==============================================================================
--- maven/components/trunk/maven-core/src/main/java/org/apache/maven/plugin/version/DefaultPluginVersionManager.java (original)
+++ maven/components/trunk/maven-core/src/main/java/org/apache/maven/plugin/version/DefaultPluginVersionManager.java Thu Jul 14 13:35:23 2005
@@ -17,6 +17,7 @@
 import org.apache.maven.project.MavenProject;
 import org.apache.maven.project.MavenProjectBuilder;
 import org.apache.maven.project.artifact.MavenMetadataSource;
+import org.apache.maven.settings.RuntimeInfo;
 import org.apache.maven.settings.Settings;
 import org.codehaus.plexus.components.inputhandler.InputHandler;
 import org.codehaus.plexus.logging.AbstractLogEnabled;
@@ -82,11 +83,14 @@
         // we're not going to prompt the user to accept a plugin update until we find one.
         boolean promptToPersist = false;
 
+        RuntimeInfo settingsRTInfo = settings.getRuntimeInfo();
+
         // determine the behavior WRT prompting the user and installing plugin updates.
-        Boolean pluginUpdateOverride = settings.getRuntimeInfo().getPluginUpdateOverride();
+        Boolean pluginUpdateOverride = settingsRTInfo.getPluginUpdateOverride();
 
-        // second pass...if the plugin is listed in the settings.xml, use the version from <useVersion/>.
-        if ( StringUtils.isEmpty( version ) )
+        // second pass...if we're using the plugin registry, and the plugin is listed in the plugin-registry.xml, use 
+        // the version from <useVersion/>.
+        if ( StringUtils.isEmpty( version ) && settings.isUsePluginRegistry() )
         {
             // resolve existing useVersion.
             version = resolveExistingFromPluginRegistry( groupId, artifactId );
@@ -102,8 +106,8 @@
                 if ( Boolean.TRUE.equals( pluginUpdateOverride )
                     || ( !Boolean.FALSE.equals( pluginUpdateOverride ) && shouldCheckForUpdates( groupId, artifactId ) ) )
                 {
-                    updatedVersion = resolveMetaVersion( groupId, artifactId, project
-                        .getPluginArtifactRepositories(), localRepository, ReleaseArtifactTransformation.RELEASE_VERSION );
+                    updatedVersion = resolveMetaVersion( groupId, artifactId, project.getPluginArtifactRepositories(),
+                                                         localRepository, ReleaseArtifactTransformation.RELEASE_VERSION );
 
                     if ( StringUtils.isNotEmpty( updatedVersion ) && !updatedVersion.equals( version ) )
                     {
@@ -120,23 +124,31 @@
                         }
                         else
                         {
-                            getLogger()
-                                .info( "Plugin \'" + constructPluginKey( groupId, artifactId ) + "\' has updates." );
+                            getLogger().info(
+                                              "Plugin \'" + constructPluginKey( groupId, artifactId )
+                                                  + "\' has updates." );
                         }
                     }
                 }
             }
         }
-        
+
         boolean forcePersist = false;
 
-        // third pass...retrieve the version for RELEASE and also set that resolved version as the <useVersion/> 
-        // in settings.xml.
-        if ( StringUtils.isEmpty( version ) )
+        // are we using the LATEST metadata to resolve plugin version?
+        Boolean rtCheckLatest = settingsRTInfo.getCheckLatestPluginVersion();
+
+        boolean checkLatestMetadata = Boolean.TRUE.equals( rtCheckLatest )
+            || ( !Boolean.FALSE.equals( rtCheckLatest ) && Boolean.valueOf( pluginRegistry.getCheckLatest() )
+                .booleanValue() );
+
+        // third pass...if we're checking for latest install/deploy, retrieve the version for LATEST metadata and also 
+        // set that resolved version as the <useVersion/> in settings.xml.
+        if ( StringUtils.isEmpty( version ) && checkLatestMetadata )
         {
             // 1. resolve the version to be used
             version = resolveMetaVersion( groupId, artifactId, project.getPluginArtifactRepositories(),
-                                             localRepository, ReleaseArtifactTransformation.RELEASE_VERSION );
+                                          localRepository, LatestArtifactTransformation.LATEST_VERSION );
 
             // 2. Set the updatedVersion so the user will be prompted whether to make this version permanent.
             updatedVersion = version;
@@ -146,13 +158,13 @@
             promptToPersist = false;
         }
 
-        // final pass...retrieve the version for LATEST and also set that resolved version as the <useVersion/> 
+        // final pass...retrieve the version for RELEASE and also set that resolved version as the <useVersion/> 
         // in settings.xml.
         if ( StringUtils.isEmpty( version ) )
         {
             // 1. resolve the version to be used
             version = resolveMetaVersion( groupId, artifactId, project.getPluginArtifactRepositories(),
-                                             localRepository, LatestArtifactTransformation.LATEST_VERSION );
+                                          localRepository, ReleaseArtifactTransformation.RELEASE_VERSION );
 
             // 2. Set the updatedVersion so the user will be prompted whether to make this version permanent.
             updatedVersion = version;
@@ -169,73 +181,78 @@
                                                         "Failed to resolve a valid version for this plugin" );
         }
 
-        // determine whether this build is running in interactive mode
-        // If it's not, then we'll defer to the autoUpdate setting from the registry 
-        // for a decision on updating the plugin in the registry...rather than prompting
-        // the user.
-        boolean inInteractiveMode = settings.isInteractiveMode();
-
-        // determines what should be done if we're in non-interactive mode.
-        // if true, then just update the registry with the new versions.
-        String s = getPluginRegistry( groupId, artifactId ).getAutoUpdate();
-        boolean autoUpdate = true;
-        if ( s != null )
-        {
-            autoUpdate = Boolean.valueOf( s ).booleanValue();
-        }
-
-        // We should persist by default if:
-        //
-        // 0. RELEASE or LATEST was used to resolve the plugin version (it's not in the registry)
-        //
-        // -OR-
-        //
-        // 1. we detected a change in the plugin version from what was in the registry, or
-        //      a. the plugin is not registered
-        // 2. the pluginUpdateOverride flag has NOT been set to Boolean.FALSE (suppression mode)
-        // 3. we're in interactive mode, or
-        //      a. the registry is declared to be in autoUpdate mode
-        //
-        // NOTE: This is only the default value; it may be changed as the result of prompting the user.
-        boolean persistUpdate = forcePersist || ( promptToPersist && !Boolean.FALSE.equals( pluginUpdateOverride )
-            && ( inInteractiveMode || autoUpdate ) );
-
-        // retrieve the apply-to-all flag, if it's been set previously.
-        Boolean applyToAll = settings.getRuntimeInfo().getApplyToAllPluginUpdates();
-
-        // Incorporate interactive-mode CLI overrides, and previous decisions on apply-to-all, if appropriate.
-        //
-        // don't prompt if RELEASE or LATEST was used to resolve the plugin version
-        // don't prompt if not in interactive mode.
-        // don't prompt if the CLI pluginUpdateOverride is set (either suppression or force mode will stop prompting)
-        // don't prompt if the user has selected ALL/NONE previously in this session
-        //
-        // NOTE: We're incorporating here, to make the usages of this check more consistent and 
-        // resistant to change.
-        promptToPersist = promptToPersist && pluginUpdateOverride == null && applyToAll == null && inInteractiveMode;
-
-        if ( promptToPersist )
-        {
-            persistUpdate = promptToPersistPluginUpdate( version, updatedVersion, groupId, artifactId, settings );
-        }
-
-        // if it is determined that we should use this version, persist it as useVersion.
-        // cases where this version will be persisted:
-        // 1. the user is prompted and answers yes or all
-        // 2. the user has previously answered all in this session
-        // 3. the build is running in non-interactive mode, and the registry setting is for auto-update
-        if ( !Boolean.FALSE.equals( applyToAll ) && persistUpdate )
-        {
-            updatePluginVersionInRegistry( groupId, artifactId, updatedVersion );
-
-            // we're using the updated version of the plugin in this session as well.
-            version = updatedVersion;
-        }
-        // otherwise, if we prompted the user to update, we should treat this as a rejectedVersion, and
-        // persist it iff the plugin pre-exists and is in the user-level registry.
-        else if ( promptToPersist )
+        // if the plugin registry is inactive, then the rest of this goop is useless...
+        if ( settings.isUsePluginRegistry() )
         {
-            addNewVersionToRejectedListInExisting( groupId, artifactId, updatedVersion );
+            // determine whether this build is running in interactive mode
+            // If it's not, then we'll defer to the autoUpdate setting from the registry 
+            // for a decision on updating the plugin in the registry...rather than prompting
+            // the user.
+            boolean inInteractiveMode = settings.isInteractiveMode();
+
+            // determines what should be done if we're in non-interactive mode.
+            // if true, then just update the registry with the new versions.
+            String s = getPluginRegistry( groupId, artifactId ).getAutoUpdate();
+            boolean autoUpdate = true;
+            if ( s != null )
+            {
+                autoUpdate = Boolean.valueOf( s ).booleanValue();
+            }
+
+            // We should persist by default if:
+            //
+            // 0. RELEASE or LATEST was used to resolve the plugin version (it's not in the registry)
+            //
+            // -OR-
+            //
+            // 1. we detected a change in the plugin version from what was in the registry, or
+            //      a. the plugin is not registered
+            // 2. the pluginUpdateOverride flag has NOT been set to Boolean.FALSE (suppression mode)
+            // 3. we're in interactive mode, or
+            //      a. the registry is declared to be in autoUpdate mode
+            //
+            // NOTE: This is only the default value; it may be changed as the result of prompting the user.
+            boolean persistUpdate = forcePersist
+                || ( promptToPersist && !Boolean.FALSE.equals( pluginUpdateOverride ) && ( inInteractiveMode || autoUpdate ) );
+
+            // retrieve the apply-to-all flag, if it's been set previously.
+            Boolean applyToAll = settings.getRuntimeInfo().getApplyToAllPluginUpdates();
+
+            // Incorporate interactive-mode CLI overrides, and previous decisions on apply-to-all, if appropriate.
+            //
+            // don't prompt if RELEASE or LATEST was used to resolve the plugin version
+            // don't prompt if not in interactive mode.
+            // don't prompt if the CLI pluginUpdateOverride is set (either suppression or force mode will stop prompting)
+            // don't prompt if the user has selected ALL/NONE previously in this session
+            //
+            // NOTE: We're incorporating here, to make the usages of this check more consistent and 
+            // resistant to change.
+            promptToPersist = promptToPersist && pluginUpdateOverride == null && applyToAll == null
+                && inInteractiveMode;
+
+            if ( promptToPersist )
+            {
+                persistUpdate = promptToPersistPluginUpdate( version, updatedVersion, groupId, artifactId, settings );
+            }
+
+            // if it is determined that we should use this version, persist it as useVersion.
+            // cases where this version will be persisted:
+            // 1. the user is prompted and answers yes or all
+            // 2. the user has previously answered all in this session
+            // 3. the build is running in non-interactive mode, and the registry setting is for auto-update
+            if ( !Boolean.FALSE.equals( applyToAll ) && persistUpdate )
+            {
+                updatePluginVersionInRegistry( groupId, artifactId, updatedVersion );
+
+                // we're using the updated version of the plugin in this session as well.
+                version = updatedVersion;
+            }
+            // otherwise, if we prompted the user to update, we should treat this as a rejectedVersion, and
+            // persist it iff the plugin pre-exists and is in the user-level registry.
+            else if ( promptToPersist )
+            {
+                addNewVersionToRejectedListInExisting( groupId, artifactId, updatedVersion );
+            }
         }
 
         return version;
@@ -587,26 +604,26 @@
     }
 
     private String resolveMetaVersion( String groupId, String artifactId, List remoteRepositories,
-                                         ArtifactRepository localRepository, String metaVersionId )
+                                      ArtifactRepository localRepository, String metaVersionId )
         throws PluginVersionResolutionException
     {
-        Artifact artifact = artifactFactory.createArtifact( groupId, artifactId, metaVersionId,
-                                                                   Artifact.SCOPE_RUNTIME, "pom" );
-        
+        Artifact artifact = artifactFactory.createArtifact( groupId, artifactId, metaVersionId, Artifact.SCOPE_RUNTIME,
+                                                            "pom" );
+
         MavenMetadataSource metadataSource = new MavenMetadataSource( artifactResolver, projectBuilder, artifactFactory );
-        
+
         String version = null;
         try
         {
             metadataSource.retrieve( artifact, localRepository, remoteRepositories );
 
-            version = artifact.getBaseVersion();
+            version = artifact.getVersion();
         }
         catch ( ArtifactMetadataRetrievalException e )
         {
             getLogger().debug( "Failed to resolve " + metaVersionId + " version", e );
         }
-        
+
         return version;
     }
 

Modified: maven/components/trunk/maven-plugin-registry/plugin-registry.mdo
URL: http://svn.apache.org/viewcvs/maven/components/trunk/maven-plugin-registry/plugin-registry.mdo?rev=219089&r1=219088&r2=219089&view=diff
==============================================================================
--- maven/components/trunk/maven-plugin-registry/plugin-registry.mdo (original)
+++ maven/components/trunk/maven-plugin-registry/plugin-registry.mdo Thu Jul 14 13:35:23 2005
@@ -78,6 +78,12 @@
           <description>Specifies whether the user should be prompted to update plugins.</description>
         </field>
         <field>
+          <name>checkLatest</name>
+          <version>1.0.0</version>
+          <type>String</type>
+          <description>Whether to resolve plugin versions using LATEST metadata.</description>
+        </field>
+        <field>
           <name>plugins</name>
           <version>1.0.0</version>
           <description>Specified plugin update policy information.</description>

Modified: maven/components/trunk/maven-settings/settings.mdo
URL: http://svn.apache.org/viewcvs/maven/components/trunk/maven-settings/settings.mdo?rev=219089&r1=219088&r2=219089&view=diff
==============================================================================
--- maven/components/trunk/maven-settings/settings.mdo (original)
+++ maven/components/trunk/maven-settings/settings.mdo Thu Jul 14 13:35:23 2005
@@ -85,6 +85,13 @@
           <type>boolean</type>
           <defaultValue>true</defaultValue>
         </field>
+        <field>
+          <name>usePluginRegistry</name>
+          <version>1.0.0</version>
+          <description><![CDATA[Whether Maven should use the plugin-registry.xml file to manage plugin versions.]]></description>
+          <type>boolean</type>
+          <defaultValue>true</defaultValue>
+        </field>
         <!-- [JC] Not ready to use yet, so I'm making if unavailable for now. -->
         <!-- field>
           <name>passwordStore</name>

Modified: maven/components/trunk/maven-settings/src/main/java/org/apache/maven/settings/RuntimeInfo.java
URL: http://svn.apache.org/viewcvs/maven/components/trunk/maven-settings/src/main/java/org/apache/maven/settings/RuntimeInfo.java?rev=219089&r1=219088&r2=219089&view=diff
==============================================================================
--- maven/components/trunk/maven-settings/src/main/java/org/apache/maven/settings/RuntimeInfo.java (original)
+++ maven/components/trunk/maven-settings/src/main/java/org/apache/maven/settings/RuntimeInfo.java Thu Jul 14 13:35:23 2005
@@ -25,11 +25,17 @@
 
     private File file;
     
+    // using Boolean for 3VL (null for not-set, otherwise override with value)
     private Boolean pluginUpdateForced;
     
     // using Boolean for 3VL (null, true-to-all, false-to-all)
     private Boolean applyToAllPluginUpdates;
     
+    private boolean pluginRegistryActive = true;
+    
+    // using Boolean for 3VL (null for not-set, otherwise override with value)
+    private Boolean checkLatest;
+    
     private Map activeProfileToSourceLevel = new HashMap();
     
     private String localRepositorySourceLevel = TrackableBase.USER_LEVEL;
@@ -119,6 +125,16 @@
     public String getLocalRepositorySourceLevel()
     {
         return localRepositorySourceLevel;
+    }
+    
+    public void setCheckLatestPluginVersion( Boolean checkLatest )
+    {
+        this.checkLatest = checkLatest;
+    }
+    
+    public Boolean getCheckLatestPluginVersion()
+    {
+        return checkLatest;
     }
 
 }



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org