Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Best way to test for zsh features?
- X-seq: zsh-users 14608
- From: john_oshea@xxxxxxxxxxxx
- To: zsh-users@xxxxxxx
- Subject: Best way to test for zsh features?
- Date: Wed, 25 Nov 2009 16:41:20 +0000
- List-help: <mailto:zsh-users-help@zsh.org>
- List-id: Zsh Users List <zsh-users.zsh.org>
- List-post: <mailto:zsh-users@zsh.org>
- Mailing-list: contact zsh-users-help@xxxxxxx; run by ezmlm
Hi all,
What's the best/cleanest/most "correct" way of checking for zsh features
in an .zshrc? I've started to use vcs_info as part of my prompt, which
works wonderfully in zsh's new enough to have that available, but gives
me "function definition file not found" on machines with older zsh
installations (that I'm unable to upgrade).
Testing $ZSH_VERSION springs to mind, but I'm wondering if there's a way
to do the equivalent of vim's "has('feature_x')" to see if the zsh I'm
in has vcs_info available?
Apologies in advance if I'm missing something very obvious...
Thanks
John
--
John O'Shea
Wordbank Limited
33 Charlotte Street, London W1T 1RR
Direct line: +44 (0) 20 7903 8829
Fax: +44 (0) 20 7903 8888
<http://www.wordbank.com/>
Messages sorted by:
Reverse Date,
Date,
Thread,
Author