Class AbstractMavenExecutor

java.lang.Object
org.apache.maven.shared.release.exec.AbstractMavenExecutor
All Implemented Interfaces:
MavenExecutor, org.codehaus.plexus.logging.LogEnabled
Direct Known Subclasses:
ForkedMavenExecutor, InvokerMavenExecutor

public abstract class AbstractMavenExecutor extends Object implements MavenExecutor, org.codehaus.plexus.logging.LogEnabled
  • Field Details

    • logger

      private org.codehaus.plexus.logging.Logger logger
    • secDispatcher

      @Requirement(role=org.sonatype.plexus.components.sec.dispatcher.SecDispatcher.class, hint="mng-4384") private org.sonatype.plexus.components.sec.dispatcher.DefaultSecDispatcher secDispatcher
      When this plugin requires Maven 3.0 as minimum, this component can be removed and o.a.m.s.c.SettingsDecrypter be used instead.
    • cipher

      @Requirement private org.sonatype.plexus.components.cipher.PlexusCipher cipher
  • Constructor Details

    • AbstractMavenExecutor

      protected AbstractMavenExecutor()
  • Method Details

    • executeGoals

      public void executeGoals(File workingDirectory, String goals, ReleaseEnvironment releaseEnvironment, boolean interactive, String additionalArguments, String pomFileName, ReleaseResult result) throws MavenExecutorException
      Description copied from interface: MavenExecutor
      Execute goals using Maven.
      Specified by:
      executeGoals in interface MavenExecutor
      Parameters:
      workingDirectory - the directory to execute in
      goals - the goals to run (space delimited)
      releaseEnvironment - the environmental settings, maven-home, etc used for this release
      interactive - whether to execute in interactive mode, or the default batch mode
      additionalArguments - additional arguments to pass to the Maven command
      pomFileName - the file name of the POM to execute on
      result - holds all results of the execution
      Throws:
      MavenExecutorException - if an error occurred executing Maven
    • executeGoals

      protected abstract void executeGoals(File workingDirectory, List<String> goals, ReleaseEnvironment releaseEnvironment, boolean interactive, String additionalArguments, String pomFileName, ReleaseResult result) throws MavenExecutorException
      Throws:
      MavenExecutorException
    • getLogger

      protected final org.codehaus.plexus.logging.Logger getLogger()
    • enableLogging

      public void enableLogging(org.codehaus.plexus.logging.Logger logger)
      Specified by:
      enableLogging in interface org.codehaus.plexus.logging.LogEnabled
    • encryptSettings

      protected org.apache.maven.settings.Settings encryptSettings(org.apache.maven.settings.Settings settings)
    • encryptAndDecorate

      private String encryptAndDecorate(String passwd) throws IllegalStateException, org.sonatype.plexus.components.sec.dispatcher.SecDispatcherException, org.sonatype.plexus.components.cipher.PlexusCipherException
      Throws:
      IllegalStateException
      org.sonatype.plexus.components.sec.dispatcher.SecDispatcherException
      org.sonatype.plexus.components.cipher.PlexusCipherException
    • isEncryptedString

      private boolean isEncryptedString(String str)
    • getSettingsWriter

      protected org.apache.maven.settings.io.xpp3.SettingsXpp3Writer getSettingsWriter()