public function remote(SubCommandCommand $subcommand = null, Array $options = array())
    {
        $normalizedOptions = $this->normalizeOptions($options, $this->remoteCmdSwitchOptions());

        $this->clearAll();

        $this->addCommandName(self::GIT_REMOTE);

        foreach ($normalizedOptions as $value) {
            $this->addCommandArgument($value);
        }

        if ($subcommand) {
            $this->addCommandSubject($subcommand);
        }

        return $this->getCommand();
    }
public function remote(SubCommandCommand $subcommand = null, Array $options = array())
    {
        $normalizedOptions = $this->normalizeOptions($options, $this->remoteCmdSwitchOptions());

        $this->clearAll();

        $this->addCommandName(self::GIT_REMOTE);

        foreach ($normalizedOptions as $value) {
            $this->addCommandArgument($value);
        }

        if ($subcommand) {
            $this->addCommandSubject($subcommand);
        }

        return $this->getCommand();
    }
public function remote ( SubCommandCommand $ subcommand = null , Array $ options = array ( ) ) { $ normalizedOptions = $ this -> normalizeOptions ( $ options , $ this -> remoteCmdSwitchOptions ( ) ) ; $ this -> clearAll ( ) ; $ this -> addCommandName ( self :: GIT_REMOTE ) ; foreach ( $ normalizedOptions as $ value ) { $ this -> addCommandArgument ( $ value ) ; } if ( $ subcommand ) { $ this -> addCommandSubject ( $ subcommand ) ; } return $ this -> getCommand ( ) ; }
Build the remote command

NOTE: git-remote is most useful when using its subcommands, therefore
in practice you will likely pass a SubCommandCommand object. This
class provide "convenience" methods that do this for you.

@param \GitElephant\Command\SubCommandCommand $subcommand A subcommand object
@param array                                  $options    Options for the main git-remote command

@throws \RuntimeException
@return string Command string to pass to caller
Build the remote command