[repo] Not everything is file dumping
This commit is contained in:
parent
6153d40f89
commit
d523f13eac
|
@ -1040,38 +1040,33 @@ namespace SparkleLib {
|
||||||
int.Parse (match.Groups [9].Value));
|
int.Parse (match.Groups [9].Value));
|
||||||
|
|
||||||
string [] entry_lines = log_entry.Split ("\n".ToCharArray ());
|
string [] entry_lines = log_entry.Split ("\n".ToCharArray ());
|
||||||
int change_count = 0;
|
|
||||||
foreach (string entry_line in entry_lines) {
|
|
||||||
|
|
||||||
if (entry_line.StartsWith (":")) {
|
if (entry_lines.Length > 60) {
|
||||||
|
|
||||||
string change_type = entry_line [37].ToString ();
|
commit.IsFileDump = true;
|
||||||
string file_path = entry_line.Substring (39);
|
|
||||||
|
|
||||||
if (change_type.Equals ("A")) {
|
} else {
|
||||||
|
|
||||||
commit.Added.Add (file_path);
|
foreach (string entry_line in entry_lines) {
|
||||||
|
|
||||||
} else if (change_type.Equals ("M")) {
|
if (entry_line.StartsWith (":")) {
|
||||||
|
|
||||||
commit.Edited.Add (file_path);
|
string change_type = entry_line [37].ToString ();
|
||||||
|
string file_path = entry_line.Substring (39);
|
||||||
|
|
||||||
} else if (change_type.Equals ("D")) {
|
if (change_type.Equals ("A")) {
|
||||||
|
|
||||||
commit.Deleted.Add (file_path);
|
commit.Added.Add (file_path);
|
||||||
|
|
||||||
}
|
} else if (change_type.Equals ("M")) {
|
||||||
|
|
||||||
change_count++;
|
commit.Edited.Add (file_path);
|
||||||
|
|
||||||
if (change_count > 50) {
|
} else if (change_type.Equals ("D")) {
|
||||||
|
|
||||||
commit.Added.Clear ();
|
commit.Deleted.Add (file_path);
|
||||||
commit.Edited.Clear ();
|
|
||||||
commit.Deleted.Clear ();
|
|
||||||
|
|
||||||
commit.IsFileDump = true;
|
}
|
||||||
break;
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue