diff --git a/utils/ls.cpp b/utils/ls.cpp index f5c06a64..5c3923ce 100644 --- a/utils/ls.cpp +++ b/utils/ls.cpp @@ -106,9 +106,14 @@ void getentrycolor(const char** pre, const char** post, mode_t mode) { *pre = ""; *post = ""; - if ( colors && S_ISDIR(mode) ) + if ( !colors ) + return; + if ( S_ISDIR(mode) ) *pre = "\e[36m", *post = "\e[37m"; + else if ( mode & 0111 ) + *pre = "\e[32m", + *post = "\e[37m"; } int handleentry(const char* path, const char* name)