More PR comment resolution.

This commit is contained in:
Patrick Shriwise 2018-10-30 20:13:36 -05:00
parent e5d8cdfc37
commit 3e36ed8e34
4 changed files with 25 additions and 33 deletions

View file

@ -11,22 +11,15 @@
#define BAR_WIDTH 72
#ifdef UNIX
int check_isatty(int fd) {
return isatty(fd);
}
#endif
bool is_terminal() {
#ifdef UNIX
return check_isatty(STDOUT_FILENO) != 0;
return isatty(STDOUT_FILENO) != 0;
#else
return false;
#endif
}
ProgressBar::ProgressBar() {
bar = "";
// initialize bar
set_value(0.0);
}