Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Disabling an option for a single statement



Hello all!

It's not uncommon that I want to disable a specific option (in my case, cdablevars) for a single statement.

Currently, I do something like:

( setopt no_cdable_vars; echo "${(D)variable}" )

Or use an anonymous function

() { setopt local_options un_cdable_vars; echo "${(D)variable}"

Are there any easier ways to achieve this?

Zach Riggle



Messages sorted by: Reverse Date, Date, Thread, Author