I teach an Intro to UNIX/Linux course at a local college and one of my students asked the following question:
Why are some of the files in my directory colored white and others are gray? Are the white ones the ones I created today and the gray are existing files?
As I looked into this I first thought the answer would be in the
LS_COLORS variable, but further investigation revealed that the color listings were different when using the
-l switch versus the
-al switch with the
ls command. See the following screen shots:
ls -l the file named '3' shows as white but using the
-al switch the same file shows a gray.
Is this a bug in ls or does anyone know why this is happening?