예제 #1
0
        public string GetDiff(string fname)
        {
            var diff  = Subproc.GetOutput("git", "diff --abbrev " + fname, Path);
            var split = diff.Split(new[] { '\n' }, 6, StringSplitOptions.None);

            return(split.Length == 6 ? split[5] : diff);
        }
예제 #2
0
 public void CheckoutBranch(string branchName)
 {
     Subproc.GetOutput("git", "checkout " + branchName, Path);
     Populate(Path);
 }
예제 #3
0
 public string[] RunGit(string arg) =>
 Subproc.GetOutput("git", arg, Path).Split('\n');