GitMonitor.vala
authorAlan Knowles <alan@roojs.com>
Fri, 2 Nov 2018 04:20:12 +0000 (12:20 +0800)
committerAlan Knowles <alan@roojs.com>
Fri, 2 Nov 2018 04:20:12 +0000 (12:20 +0800)
GitMonitor.vala

index 78315cb..4c7dfde 100644 (file)
@@ -251,14 +251,14 @@ public class GitMonitor : Monitor
                        var gitpath = cmd.gitpath; 
                        
                        var repo = GitRepo.get( gitpath );
-                       if ( !repo.isWipBranch()) {
+                       if ( !repo.is_wip_branch()) {
                                leave_queued.add(cmd);
                                continue;
                        }
                        
                        GLib.debug("GitMonitor.runQueue - finding %s", cmd.gitpath);
                
-                       var ix  = GitRepo.indexOf(repo_list,  cmd.gitpath);
+                       var ix  = GitRepo.indexOf(repo_list,   gitpath);
                        if (ix < 0) {
                                repo_list.append_val( GitRepo.get( gitpath ));
                                ix = GitRepo.indexOf(repo_list,  cmd.gitpath);
@@ -331,6 +331,9 @@ public class GitMonitor : Monitor
                                                break;
                                } 
                        }
+                       
+                       repo.cmds.clear();
+                       
                        GLib.debug( "ADD : %s", GitMonitorQueue.queueArrayToString(add_files));
                        GLib.debug( "REMOVE FILES: %s", GitMonitorQueue.queueArrayToString(remove_files));