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

Re: Overriding "builtin"



On 2022-08-12 08:12, Daniel Shahaf wrote:
[...]
«unset 'functions[unfunction]'», provided (zsh/parameter is available
and) someone hasn't created an unset() function as well.
[...]

Or the standard "unset -f builtin"

Or functions=()

(or exec zsh -f)

Or

builtin() {
  echo my builtin wrapper
  set -o localoptions -o posixbuiltins
  command builtin "$@"
}

(though that affects the behaviour of the builtin called by builtin.

--
Stephane




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