Skip to content
This repository was archived by the owner on Sep 11, 2020. It is now read-only.

Conversation

@TripleDogDare
Copy link
Contributor

The remote.upInfo is not set until Connect() is called.
However, repository.PullDefault() requires that it exists when
it calls remote.DefaultBranch(). This can be solved by pushing
the default branch discovery into repository.Pull().

The empty string "" is not a valid branch name, so by allowing
the empty string to mean 'default branch' in the Pull() function
we can allow PullDefault() to not need a remote.Connect() call
before calling repository.Pull()

Relates to issue #45

@TripleDogDare TripleDogDare force-pushed the fix-repository-pulldefault branch 2 times, most recently from 182cccb to 00710e4 Compare May 7, 2016 22:57
The `remote.upInfo` is not set until `Connect()` is called.
However, `repository.PullDefault()` requires that it exists when
it calls `remote.DefaultBranch()`. This can be solved by pushing
the default branch discovery into `repository.Pull()`.

The empty string "" is not a valid branch name, so by allowing
the empty string to mean 'default branch' in the `Pull()` function
we can allow `PullDefault()` to not need a `remote.Connect()` call
before calling `repository.Pull()`
@TripleDogDare TripleDogDare force-pushed the fix-repository-pulldefault branch from 00710e4 to 213eb79 Compare May 7, 2016 22:58
@mcuadros mcuadros merged commit 743680b into src-d:master May 8, 2016
mcuadros added a commit that referenced this pull request Jan 31, 2017
gsalingu-ovhus pushed a commit to gsalingu-ovhus/go-git that referenced this pull request Mar 28, 2019
Add test for Streaming mode
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants