Adds a new remote repository to the local repository

cli equivalent: git remote add $name $url

@param string $url The url of the remote repository
@param string $name The name of the remote repository, defaults to origin
@return self
511255
public function addRemote($url, $name = 'origin') {
    $this->getRunnerWithDirectory()->run($this->getResettedCommandBuilder()->addSubcommand('remote')->addSubcommand('add')->addParam($name)->addParam($url));
    return $this;
  }
183986
public function add($name, $url, $options = array())
    {
        $subcmd = new AddSubCommand();
        $subcmd->prepare($name, $url, $options);

        return $this->remote($subcmd);
    }
300595
public Repository addRepository( String name,
                                     HttpServletRequest request ) {
        Repository repository = new Repository(name, request);
        repositories.add(repository);
        return repository;
    }
704855
public function addInstallScript($name, $file, $url)
    {
        $scriptElement = new InstallScript($name, $file, $url);
        return $this->addElement($scriptElement);
    }
398987
public function addPlayMap($name, $url)
    {
        $mapElement = new PlayMap($name, $url);
        return $this->addElement($mapElement);
    }
1037347
public static function URL($name, $params = []){
      return ($r = static::tagged($name)) ? $r-> getURL($params) : new URL();
    }
183686
public function installRepository(string $name, string $type, string $url)
    {
        if (array_key_exists('repositories', $this->definition)
            && array_key_exists($name, $this->definition['repositories'])
        ) {
            return;
        }

        $application = new Application();
        $command     = new ConfigCommand();

        $definition = clone $application->getDefinition();
        $definition->addArguments($command->getDefinition()->getArguments());
        $definition->addOptions($command->getDefinition()->getOptions());

        $input = new ArrayInput(
            [
                'command' => 'config',
                'setting-key' => 'repositories.' . $name,
                'setting-value' => [
                    $type,
                    $url
                ],
                '--working-dir' => $this->workingDir
            ],
            $definition
        );

        $application->setAutoExit(false);
        $application->run($input, $this->output);
    }
118161
public function addInstallSkin($name, $file, $url)
    {
        $skinElement = new InstallSkin($name, $file, $url);
        return $this->addElement($skinElement);
    }
1317395
public function setBaseUrl($url) {
		if ($url === '/' || $url === '//') {
			$this->baseUrl = $url;
			return;
		}
		
		$this->baseUrl = rtrim($url, '/') . '/';
		
		return $this;
	}
323305
public static function createNewClient(string $name, $redirectUris = null): Client
    {
        if (isset($redirectUris) && is_string($redirectUris)) {
            $redirectUris = explode(' ', $redirectUris);
        }

        if (isset($redirectUris) && is_array($redirectUris)) {
            foreach ($redirectUris as &$redirectUri) {
                $redirectUri = trim((string) $redirectUri);
            }
        }

        $client = new static();

        $client->id = (string) Uuid::uuid4();
        $client->name = $name;
        $client->redirectUris = $redirectUris ?? [];

        return $client;
    }
111885
public static function _createFromServer($name, $url)
    {
        $file = new AVFile();
        $file->name = $name;
        $file->url = $url;

        return $file;
    }
55134
public function setUrl($url): self
    {
        if (\is_string($url)) {
            $this->options['url'] = $url;

            return $this;
        }

        if ($url instanceof Leg) {
            $this->setUrlFromLeg($url);

            return $this;
        }

        if ($url instanceof BoardData) {
            $this->setUrlFromBoardData($url);

            return $this;
        }

        throw new \InvalidArgumentException(
            sprintf('setUrl must be a string, Leg or BoardData object')
        );
    }
89062
def set_remote_url(name, url)
      url = url.repo.path if url.is_a?(Git::Base)
      self.lib.remote_set_url(name, url)
      Git::Remote.new(self, name)
    end
155886
public function addInstallPack($name, $file, $url)
    {
        $packElement = new InstallPack($name, $file, $url);
        return $this->addElement($packElement);
    }
903056
public void addRemoteRepositoryByUrl(String url, String username, String password) throws URLException {
        RemoteRepository remoteRepo;
        try {
            remoteRepo = RepoBuilder.remoteRepositoryFromUrl(url);
        } catch (MalformedURLException e) {
            throw new URLException(e);
        }
        remoteRepo = remoteRepo.setAuthentication(new Authentication(username, password));
        addRemoteRepository(remoteRepo);
    }
822749
public static function create($name, $alias, $url) : self
    {
        $self = new static();
        $self->name  = $name;
        $self->alias = $alias;
        $self->url   = $url;
        $self->created_by = Yii::$app->user->identity->id;
        $self->updated_by = Yii::$app->user->identity->id;
        return $self;
    }
1273088
public function addBreadcrumbLink($name, $url = '', $icon = '')
    {
        $this->breadcrumbItems->push((object) ['name' => $name, 'url' => $url, 'icon' => $icon]);
    }