]> ruderich.org/simon Gitweb - config/dotfiles.git/blobdiff - shell/env
Use colorized output with normal ls when GNU ls is not available.
[config/dotfiles.git] / shell / env
index a7f7405049710bec78eae1bc0e25a7bc3a7743e2..84705b62d57af4eac107905443f3703d33f4e413 100644 (file)
--- a/shell/env
+++ b/shell/env
@@ -13,13 +13,29 @@ export EDITOR
 PAGER=less
 export PAGER
 
-# Set colors for ls (and zsh completions). This colors files normal (fi),
+# Set colors for GNU ls (and zsh completions). This colors files normal (fi),
 # directories blue bold (di), symbolic links cyan (ln), named pipes normal
 # (pi), sockets normal (so), block devices normal (bd), character devices
 # normal (cd) and executables bold red (ex).
 # See `dircolors --print-database` for possible colors.
 LS_COLORS='no=00:fi=00:di=34;01:ln=36:pi=00:so=00:bd=00:cd=00:ex=31;01'
 export LS_COLORS
+# Set the same colors for non GNU ls.
+LSCOLORS='ExgxxxxxBxxxxxBxBxExEx'
+#         ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^
+#         | | | | | | | | | | |
+#         | | | | | | | | | | *- directory writable to others, without sticky bit
+#         | | | | | | | | | *--- directory writable to others, with sticky bit
+#         | | | | | | | | *----- executable with setgid bit set
+#         | | | | | | | *------- executable with setuid bit set
+#         | | | | | | *--------- character special
+#         | | | | | *----------- block special
+#         | | | | *------------- executable
+#         | | | *--------------- pipe
+#         | | *----------------- socket
+#         | *------------------- symbolic link
+#         *--------------------- directory
+export LSCOLORS
 
 
 # Sources a configuration file if it exists; loads a fallback .local file if