mirror of
https://github.com/robbyrussell/oh-my-zsh.git
synced 2026-11-24 01:13:03 +01:00
`diff --color` and `ls -G` (or `--color`, `gls`, `colorls` depending on the OS) were probed with a fork each on every startup. Remember the results in $ZSH_CACHE_DIR for a day, the same way lib/grep.zsh does. The ls section is wrapped in an anonymous function so that the early return for DISABLE_LS_COLORS still runs the cleanup at the end of the file. Behaviour is otherwise unchanged. Measured on macOS arm64, zsh 5.9: 5.7 ms -> 0.7 ms per interactive start. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>