GitBranch.vala
authorAlan Knowles <alan@roojs.com>
Wed, 20 Mar 2019 06:40:34 +0000 (14:40 +0800)
committerAlan Knowles <alan@roojs.com>
Wed, 20 Mar 2019 06:40:34 +0000 (14:40 +0800)
GitBranch.vala

index b2a8f70..3d485ef 100644 (file)
@@ -54,6 +54,20 @@ public class GitBranch : Object
        {
                this.repo = repo;
        }
+       
+       public void loadRemoteHeads(bool force = false)
+       {
+               
+               if (!force && this.remote_heads != null) {
+                       return;
+               }
+               var r = this.repo.lookup_remote("origin");
+               r.connect(Ggit.Direction.FETCH, this.callbacks, null, null);
+               this.remote_heads = r.list();
+       
+       }
+       
+       
 
        public static  void loadBranches(GitRepo repo)
        {