OpenBSD.zsh 716 B

12345678910111213141516171819202122232425262728293031323334
  1. # OpenBSD stuff
  2. # GNU ls(1) from OpenBSD ports is named gls(1)/gdircolors(1).
  3. if -exe gdircolors ; then
  4. if [ "$TERM" != "dumb" ]; then
  5. eval $(gdircolors -b)
  6. alias ls="gls -h --color=auto"
  7. alias l="gls -lh --color=auto"
  8. else
  9. alias ls="gls -h"
  10. alias l="gls -lh"
  11. fi
  12. # colorls(1) is {Open,Net}BSD port name for FreeBSD ls(1)
  13. elif -exe colorls ; then
  14. if [ "$TERM" != "dumb" ]; then
  15. export LSCOLORS="exfxbxdxcxegedabagacad"
  16. alias ls="colorls -GFh"
  17. alias l="colorls -lGFh"
  18. else
  19. alias ls="colorls -Fh"
  20. alias l="colorls -lFh"
  21. fi
  22. else
  23. alias ls="ls -Fh"
  24. fi
  25. # GNU tar is called gtar
  26. -exe gtar \
  27. && alias tar="gtar"
  28. # GNU find is called gfind
  29. -exe gfind \
  30. && alias find="gfind"