Compare commits

..

1 Commits

Author SHA1 Message Date
fa0bf6f3bf Move entire git-prompt to C 2018-09-11 18:09:41 +01:00

View File

@ -144,7 +144,6 @@ int main() {
while (NULL != fgets(status, sizeof(status) - 1, process.out)) { while (NULL != fgets(status, sizeof(status) - 1, process.out)) {
char X = status[0]; char X = status[0];
char Y = status[1]; char Y = status[1];
if (X == '?' && Y == '?') { if (X == '?' && Y == '?') {
++untracked; ++untracked;
} else if ((X == 'A' && (Y == 'A' || Y == 'U')) || } else if ((X == 'A' && (Y == 'A' || Y == 'U')) ||
@ -173,7 +172,6 @@ int main() {
} }
} }
check(process_close(process)); check(process_close(process));
if (indexed || modified || deleted || unmerged || untracked) { // modified if (indexed || modified || deleted || unmerged || untracked) { // modified
char int_buf[32]; char int_buf[32];
if (indexed) { if (indexed) {
@ -194,7 +192,6 @@ int main() {
} else { // clean } else { // clean
append(prompt, 1, "%{%B%F{2}%}✓%{%f%b%}"); append(prompt, 1, "%{%B%F{2}%}✓%{%f%b%}");
} }
// print the prompt // print the prompt
puts(prompt); puts(prompt);
return 0; return 0;