1
0
Fork 0
mirror of synced 2024-05-24 19:15:21 -04:00
zimfw/src/stage2/20_guard.zsh.erb
Eric Nielsen be2be83560
Check the latest version using git ls-remote
which is being used to list the latest tag starting with `v`.
Print a warning if it's different than the current version being used.
2020-01-13 13:14:31 -05:00

8 lines
310 B
Plaintext

autoload -Uz is-at-least && if ! is-at-least <%= min_zsh_version %>; then
print -u2 -PR "%F{red}${0}: Error starting Zim. You're using Zsh version %B${ZSH_VERSION}%b and versions < %B<%= min_zsh_version %>%b are not supported. Upgrade your Zsh.%f"
return 1
fi
# Define Zim location
: ${ZIM_HOME=${0:A:h}}