diff --git a/src/httpd.js.c b/src/httpd.js.c index 1e61606c..961df4a8 100644 --- a/src/httpd.js.c +++ b/src/httpd.js.c @@ -31,6 +31,10 @@ #define tf_countof(a) ((int)(sizeof((a)) / sizeof(*(a)))) +#define CYAN "\e[1;36m" +#define MAGENTA "\e[1;35m" +#define RESET "\e[0m" + const int64_t k_refresh_interval = 1ULL * 7 * 24 * 60 * 60 * 1000; static JSValue _authenticate_jwt(JSContext* context, const char* jwt); @@ -416,6 +420,7 @@ static JSValue _httpd_endpoint_start(JSContext* context, JSValueConst this_val, *listener = (httpd_listener_t) { .context = context, .tls = JS_DupValue(context, argv[1]) }; tf_tls_context_t* tls = tf_tls_context_get(listener->tls); int assigned_port = tf_http_listen(http, port, tls, _httpd_listener_cleanup, listener); + tf_printf(CYAN "~😎 Tilde Friends" RESET " is now up at " MAGENTA "http%s://127.0.0.1:%d/" RESET ".\n", tls ? "s" : "", assigned_port); return JS_NewInt32(context, assigned_port); }