Fastfetch: enable pipe mode if $NO_COLOR is set

This commit is contained in:
李通洲
2024-05-05 20:14:10 +08:00
parent 479731f076
commit 33ff4870dc
3 changed files with 3 additions and 3 deletions
+1 -1
View File
@@ -350,7 +350,7 @@ void ffOptionsInitDisplay(FFOptionsDisplay* options)
ffStrbufInitStatic(&options->keyValueSeparator, ": ");
options->showErrors = false;
options->pipe = !isatty(STDOUT_FILENO);
options->pipe = !isatty(STDOUT_FILENO) || !!getenv("NO_COLOR");
#ifdef NDEBUG
options->disableLinewrap = !options->pipe;