Class EmbeddedCommandRunner

java.lang.Object
org.apache.sshd.git.pgm.EmbeddedCommandRunner

public class EmbeddedCommandRunner extends Object
TODO Add javadoc
Author:
Apache MINA SSHD Project
  • Constructor Details

    • EmbeddedCommandRunner

      public EmbeddedCommandRunner(Path rootDir)
  • Method Details

    • execute

      public void execute(String[] argv, InputStream in, OutputStream out, OutputStream err) throws Exception
      Execute a command.
      Parameters:
      argv - the command and its arguments
      in - the input stream, may be null in which case the system input stream will be used
      out - the output stream, may be null in which case the system output stream will be used
      err - the error stream, may be null in which case the system error stream will be used
      Throws:
      Exception - if an error occurs
    • openGitDir

      protected org.eclipse.jgit.lib.Repository openGitDir(String gitdir) throws IOException
      Evaluate the --git-dir option and open the repository.
      Parameters:
      gitdir - the --git-dir option given on the command line. May be null if it was not supplied.
      Returns:
      the repository to operate on.
      Throws:
      IOException - the repository cannot be opened.