<p dir="ltr">FWIW, I always branch off upstream/master. I don't have master synced to my repo, because it just seems like an extra step. Why not go straight to the source? </p>
<div class="gmail_quote">On Oct 31, 2014 11:48 AM, "Eric Snow" <<a href="mailto:eric.snow@canonical.com">eric.snow@canonical.com</a>> wrote:<br type="attribution"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">On Fri, Oct 31, 2014 at 2:11 AM, roger peppe <<a href="mailto:roger.peppe@canonical.com">roger.peppe@canonical.com</a>> wrote:<br>
> On 30 October 2014 14:34, Eric Snow <<a href="mailto:eric.snow@canonical.com">eric.snow@canonical.com</a>> wrote:<br>
>> On Thu, Oct 30, 2014 at 4:40 AM, roger peppe <<a href="mailto:roger.peppe@canonical.com">roger.peppe@canonical.com</a>> wrote:<br>
>>> It's a pity then that if you "go get" a package, origin is the repo<br>
>>> you've branched from. There is always one of those, but you<br>
>>> don't necessary have a fork of the repo yourself.<br>
>><br>
>> Why wouldn't you want go get to fetch from your clone by default?<br>
><br>
> What Andrew said.<br>
><br>
> Also, the only information that "go get" has when a repository<br>
> doesn't exist locally is the home of that repository.<br>
> So when "go get" gets a new package, the only place<br>
> that origin can point to is that repository's home.<br>
<br>
Right. I'm not suggesting that "go get" (or godeps) change the<br>
remotes for a repo that didn't already have a local clone, nor even<br>
for any existing local clones. In fact, I'm saying that the current<br>
behavior of "go get" is just fine. It shouldn't need to worry about<br>
any other remotes than "origin", regardless of if the local clone<br>
already existed. Neither should it worry about where "origin" is<br>
pointing, nor about syncing origin with upstream.<br>
<br>
If someone has pointed "origin" to point to their own remote [1] clone<br>
(which is what the juju CONTRIBUTING doc suggests), then they are<br>
responsible for keeping that synced up with upstream. If they don't<br>
and godeps has issues because it can't find the revision it wants,<br>
that isn't the fault of godeps or "go get".<br>
<br>
I believe the request from earlier (Tim?) is that godeps help out in<br>
that case. [2][3] However, that should not require that "go get" have<br>
any awareness of remotes.<br>
<br>
><br>
> When starting work on a package, the first thing I will do is<br>
> invariably "go get" that package, which will fetch all new dependencies<br>
> too. For the majority of those dependencies, I won't already<br>
> have forked them on github. If I come to start work on<br>
> one of those dependencies, it will already have an "origin"<br>
> remote pointing to the source of the repo.<br>
><br>
> So it's much easier IMHO just to go with the flow and keep origin<br>
> always meaning the same thing, whether you've forked the<br>
> repo or not.<br>
<br>
Right. That is fine and should not change, nor need to. It's the<br>
case where you did change your remotes that godeps *could* be more<br>
helpful, regardless of whether or not it's worth doing.<br>
<br>
-eric<br>
<br>
[1] I suppose you could also point "origin" to another repo elsewhere<br>
on your local filesystem.<br>
[2] I was going to pull this conversation into a feature request on<br>
the godeps issue tracker, since it is basically a distraction from the<br>
original thread topic. However, I didn't find any such tracker. The<br>
launchpad project does not seem to have one enabled and there is no<br>
github repo,<br>
[3] Regarding the feature request, here's a possible solution. If the<br>
revision for a repo is not found in "origin" (after running "go get"),<br>
look for it in "upstream" (if that remote exists). If "upstream"<br>
exists but the revision isn't there, give a warning that "upstream"<br>
may be out of date. I suppose godeps could also try fetching from<br>
upstream first (without pushing any changes to upstream).<br>
</blockquote></div>