Adds a remote to the repository.
public addRemote ( string $name, string $url, array $options = [] ) : |
||
$name | string | The name of the remote to add. |
$url | string | The URL of the remote to add. |
$options | array | An associative array of options, with the following keys:
- -f: Boolean, set to true to run git fetch immediately after the
remote is set up. Defaults to false.
- --tags: Boolean. By default only the tags from the fetched branches
are imported when git fetch is run. Set this to true to import every
tag from the remote repository. Defaults to false.
- --no-tags: Boolean, when set to true, git fetch does not import tags
from the remote repository. Defaults to false.
- -t: Optional array of branch names to track. If left empty, all
branches will be tracked.
- -m: Optional name of the master branch to track. This will set up a
symbolic ref 'refs/remotes/ |
return |