}
- Ggit.Branch? getBranch(string remote_name)
+ Ggit.Branch? getBranch(string remote_name, string remote_branch_name)
{
- GLib.debug("lookup %s", remote_name);
+
+ var target = remote_branch_name.replace("refs/heads/", remote_name+"/") .replace("refs/remotes/", "");
+
+
foreach(var br in this.branches) {
- if (br.get_upstream().get_short_name() == remote_name) {
+ // GLib.debug("test:%s=%s", br.get_upstream().get_shorthand() , target);
+ if ( br.get_upstream().get_shorthand() == target) {
return br;
}
}
- GLib.debug("missing %s", remote_name);
+ //GLib.debug("missing %s", remote_branch_name);
return null;
}
var heads = r.list();
foreach(var rh in heads) {
- var br = this.getBranch(rh.get_name());
+ var br = this.getBranch(n, rh.get_name());
GLib.debug("got heads: name=%s rev=%s localrev=%s",
rh.get_name(),