Is it possible to make
ls distinguish executable scripts from actual compiled binaries?
The permissions are most often the same (
+x), and with
ls -F you get an asterisk suffix (
*) for both, so it's hard to tell them apart. I have a script to setup the colors of
ls, but it relies on the file being executable or not, so they show up the same:
BG='01;32' # green
EX="ex=$BG" # file with execute permission
I don't want to depend on the extension as so many of these files don't have it.
I want this so when I see some bizarre error message and think, "What code caused that?", I know whether or not it's safe to
cat the file.
If there is no standard solution, what about parsing the output of
file, in one common function, and inserting some distinctive mark? Or would that be much too slow for