else if (startswith(r, "Fedora"))
status_printf("Welcome to \x1B[0;34m%s\x1B[0m!\n", r); /* Blue for Fedora */
else
- status_printf("Welcome to %s!\n", r);
+ status_printf("Welcome to \x1B[1m%s\x1B[0m!\n", r); /* Highlight for everything else */
free(r);
environ[j] = NULL;
}
+const char *default_term_for_tty(const char *tty) {
+ assert(tty);
+
+ if (startswith(tty, "/dev/"))
+ tty += 5;
+
+ if (startswith(tty, "tty") &&
+ tty[3] >= '0' && tty[3] <= '9')
+ return "TERM=linux";
+
+ /* FIXME: Proper handling of /dev/console would be cool */
+
+ return "TERM=vt100-nav";
+}
+
static const char *const ioprio_class_table[] = {
[IOPRIO_CLASS_NONE] = "none",
[IOPRIO_CLASS_RT] = "realtime",